Skip to content

Commit b2201b6

Browse files
committed
Update Request.php
1 parent 50c8ecf commit b2201b6

1 file changed

Lines changed: 1 addition & 4 deletions

File tree

src/Request.php

Lines changed: 1 addition & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -135,13 +135,10 @@ public static function getMethod() {
135135
$meth = getenv('REQUEST_METHOD');
136136

137137
if ($meth === false) {
138-
$meth = $_SERVER['REQUEST_METHOD'];
138+
$meth = isset($_SERVER['REQUEST_METHOD']) ? $_SERVER['REQUEST_METHOD'] : '';
139139
}
140140
$method = filter_var($meth, FILTER_SANITIZE_STRING);
141141

142-
if ($method === false) {
143-
144-
}
145142

146143
if (!in_array($method, self::METHODS)) {
147144
$method = 'GET';

0 commit comments

Comments
 (0)