From 4c0d8283e31781df039bf69da59d02f72793280c Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?R=C3=A2u=20Cao?= Date: Thu, 12 Jan 2023 14:32:35 +0800 Subject: [PATCH] Make status code explicit --- app/controllers/webhooks_controller.rb | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/app/controllers/webhooks_controller.rb b/app/controllers/webhooks_controller.rb index 2efc9dc..1831ac5 100644 --- a/app/controllers/webhooks_controller.rb +++ b/app/controllers/webhooks_controller.rb @@ -6,7 +6,7 @@ class WebhooksController < ApplicationController def lndhub begin payload = JSON.parse(request.body.read, symbolize_names: true) - return unless payload[:type] == "incoming" + head :no_content and return unless payload[:type] == "incoming" rescue head :unprocessable_entity and return end