diff --git a/app/controllers/v0/forwarding_controller.rb b/app/controllers/v0/forwarding_controller.rb index b1344222..895aa521 100644 --- a/app/controllers/v0/forwarding_controller.rb +++ b/app/controllers/v0/forwarding_controller.rb @@ -6,7 +6,7 @@ def authorize username = params[:username] token = topic && get_forwarding_token(topic) authorized = token && username && User.forwarding_subscription_authorized?(token, username) - render json: { result: authorized ? "allow" : "ignore" } + render json: { result: authorized ? "allow" : "deny" } end private diff --git a/spec/requests/v0/forwarding_spec.rb b/spec/requests/v0/forwarding_spec.rb index 5a06bd69..851e926d 100644 --- a/spec/requests/v0/forwarding_spec.rb +++ b/spec/requests/v0/forwarding_spec.rb @@ -40,7 +40,7 @@ it "does not authorize the subscription" do r = api_get "/forward", params expect(response.status).to eq(200) - expect(r["result"]).to eq("ignore") + expect(r["result"]).to eq("deny") end end