Commit dd33e978 authored by Mat's avatar Mat
Browse files

Adapte la méthode pour passer le token dans l'URL

parent debb3ab9
...@@ -25,7 +25,7 @@ class TokenAuthenticator extends AbstractGuardAuthenticator ...@@ -25,7 +25,7 @@ class TokenAuthenticator extends AbstractGuardAuthenticator
*/ */
public function supports(Request $request) public function supports(Request $request)
{ {
return $request->headers->has('X-AUTH-TOKEN'); return $request->query->has('token');
} }
/** /**
...@@ -82,7 +82,7 @@ class TokenAuthenticator extends AbstractGuardAuthenticator ...@@ -82,7 +82,7 @@ class TokenAuthenticator extends AbstractGuardAuthenticator
public function getCredentials(Request $request) public function getCredentials(Request $request)
{ {
return array( return array(
'token' => $request->headers->get('X-AUTH-TOKEN'), 'token' => $request->query->get('token'),
); );
} }
......
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment