[add]: enforce content type json

This commit is contained in:
VivianDee
2025-03-21 12:12:20 +01:00
parent c0680b3098
commit 293d73518f
8 changed files with 38 additions and 26 deletions
+1 -1
View File
@@ -1 +1 @@
from .handlers import bad_request, method_not_allowed, not_found
from .handlers import method_not_allowed, unsupported_media_type
+3
View File
@@ -9,3 +9,6 @@ def not_found(error):
def bad_request(error):
return ResponseHelper.bad_request(message="Bad Request")
def unsupported_media_type(error):
return ResponseHelper.error(message="Unsupported Media Type", status_code=415)