Skip to content

Commit 2529904

Browse files
committed
Merge pull request laravel#1586 from Pasvaz/patch-1
Implemented OPTIONS verb
2 parents 63bf89e + 9dd0a21 commit 2529904

File tree

1 file changed

+4
-2
lines changed

1 file changed

+4
-2
lines changed

laravel/routing/router.php

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -33,6 +33,7 @@ class Router {
3333
'DELETE' => array(),
3434
'PATCH' => array(),
3535
'HEAD' => array(),
36+
'OPTIONS'=> array(),
3637
);
3738

3839
/**
@@ -47,6 +48,7 @@ class Router {
4748
'DELETE' => array(),
4849
'PATCH' => array(),
4950
'HEAD' => array(),
51+
'OPTIONS'=> array(),
5052
);
5153

5254
/**
@@ -97,7 +99,7 @@ class Router {
9799
*
98100
* @var array
99101
*/
100-
public static $methods = array('GET', 'POST', 'PUT', 'DELETE', 'HEAD');
102+
public static $methods = array('GET', 'POST', 'PUT', 'DELETE', 'HEAD', 'OPTIONS');
101103

102104
/**
103105
* Register a HTTPS route with the router.
@@ -594,4 +596,4 @@ protected static function repeat($pattern, $times)
594596
return implode('/', array_fill(0, $times, $pattern));
595597
}
596598

597-
}
599+
}

0 commit comments

Comments
 (0)