Browse Source

Refactoring input class to use Request::spoofed when hydrating input.

Taylor Otwell 13 years ago
parent
commit
5bea9121af
1 changed files with 1 additions and 3 deletions
  1. 1 3
      system/input.php

+ 1 - 3
system/input.php

@@ -103,9 +103,7 @@ class Input {
 
 			case 'PUT':
 			case 'DELETE':
-				// The request method can be spoofed by specifying a "REQUEST_METHOD" in the $_POST array.
-				// If the method is being spoofed, the $_POST array will be considered the input.
-				if (isset($_POST['REQUEST_METHOD']) and in_array($_POST['REQUEST_METHOD'], array('PUT', 'DELETE')))
+				if (Request::spoofed())
 				{
 					static::$input =& $_POST;
 				}