From f91943cde2e781fdc114356abcb76768aaf56af0 Mon Sep 17 00:00:00 2001 From: 0880 <98263509+0880880@users.noreply.github.com> Date: Tue, 20 Jan 2026 22:19:57 +0330 Subject: [PATCH] Fix valid method condition --- slow/slow.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/slow/slow.py b/slow/slow.py index b7c8f42..abd4725 100644 --- a/slow/slow.py +++ b/slow/slow.py @@ -100,7 +100,7 @@ class App: method: str, func: Callable[[Request, ...], Awaitable[Response]], ): - if method not in ["GET", "POST", "PUT", "DELETE"]: + if method not in ["GET", "POST", "PUT", "DELETE", "PATCH", "HEAD"]: raise RuntimeError(f'Invalid method "{method}".') pat = self._pattern_to_regex(path) if pat not in self.routes: