From 781299775d276c3599aa13d86bd9259c5cecd5a4 Mon Sep 17 00:00:00 2001 From: preciz Date: Wed, 26 Aug 2026 12:37:13 +0200 Subject: [PATCH] Skip absent method override normalization --- lib/plug/method_override.ex | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/lib/plug/method_override.ex b/lib/plug/method_override.ex index ba263f3b..cb96b7d0 100644 --- a/lib/plug/method_override.ex +++ b/lib/plug/method_override.ex @@ -58,7 +58,7 @@ defmodule Plug.MethodOverride do end defp override_method(%Plug.Conn{} = conn, body_params) do - with method when is_binary(method) <- body_params["_method"] || "", + with method when is_binary(method) <- body_params["_method"], method = String.upcase(method, :ascii), true <- method in @allowed_methods do %{conn | method: method}