Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- protected function handleAuth(){
- $login = $this->request->getUser();
- $password = $this->request->getPassword();
- $user = $this->get('doctrine.orm.entity_manager');
- if (!$user)
- {
- return $this->sendResponse(array('msg'=>'User not found'),404);
- }
- $user = $user[0];
- if(!password_verify($data['password'], $user->getUserPass())){
- return $this->sendResponse(array('msg'=>'Invalid credentials'),401);
- }
- return true;
- }
- Error: Call to a member function get() on a non-object
- in vendor/symfony/symfony/src/Symfony/Bundle/FrameworkBundle/Controller/Controller.php at line 391
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement