/** * Determine if the user is authorized to make this request. * * @return bool */ public function authorize(EmailConfirmationRepository $tokens) { return $tokens->verify($this->email, $this->token); }
/** * Determine if the user is authorized to make this request. * * @return bool */ public function authorize(EmailConfirmationRepository $tokens) { return $tokens->verify($this->input('new_email'), $this->token) && JWTAuth::parseToken()->authenticate(); }