Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

PHP 5.3.3 #19

Open
tomec-martin opened this issue Jan 2, 2017 · 1 comment
Open

PHP 5.3.3 #19

tomec-martin opened this issue Jan 2, 2017 · 1 comment

Comments

@tomec-martin
Copy link

We are forced to use PHP 5.3.3 and TinyRest seems to work fine with it. We only need to apply this simple patch - can you merge it to master?

 Flame/Rest/Security/Cors.php | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git ./flame/tiny-rest/Flame/Rest/Security/Cors.php b/Flame/Rest/Security/Cors.php
index 22a2fbe..71a0add 100644
--- ./flame/tiny-rest/Flame/Rest/Security/Cors.php
+++ ./flame/tiny-rest/Flame/Rest/Security/Cors.php
@@ -83,7 +83,7 @@ class Cors extends Object implements ICors
                                 * Because OPTIONS requests aren't contain declared headers but send list of
                                 * headers in Access-Control-Request-Headers header
                                 */
-                               $expectedHeaders = $this->httpRequest->getHeader("Access-Control-Request-Headers", []);
+                               $expectedHeaders = $this->httpRequest->getHeader("Access-Control-Request-Headers", array());
                                if (!empty($expectedHeaders)) {
                                        $expectedHeaders = array_map('trim', explode(",", $expectedHeaders));
                                }
@jsifalda
Copy link
Member

jsifalda commented Jan 3, 2017

Can you create pull request? It would be highly appreciated :)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants