diff --git a/.gitignore b/.gitignore new file mode 100644 index 0000000..a22d218 --- /dev/null +++ b/.gitignore @@ -0,0 +1,2 @@ +/node_modules +/.vscode \ No newline at end of file diff --git a/build/api/core/Request.php b/build/api/core/Request.php index 7ed7e83..efc3f4f 100755 --- a/build/api/core/Request.php +++ b/build/api/core/Request.php @@ -103,7 +103,7 @@ $params = (is_array($params)) ? $params : []; /* (3) On définit en constante la méthode HTTP */ - if( !isset($_SERVER['REQUEST_METHOD']) || !is_string($forced_method) ) + if( !isset($_SERVER['REQUEST_METHOD']) && !is_string($forced_method) ) return $this->error->set(Err::UnknownHttpMethod); $this->http_method = is_string($forced_method) ? strtoupper($forced_method) : strtoupper($_SERVER['REQUEST_METHOD']);