original_string: public function login (Request $request, User $user, $registration = false)
      {
          // Check for email validation
          if ($this->requiresEmailValidation()) {
              if (!$user->isEmailVerified()) {
                  $request->getSession()->set ('catlab-non-verified-user-id', $user->getId());
                  return Response::redirect(URLBuilder::getURL($this->routepath . '/notverified'));
              }
          }
  
          $request->getSession()->set('catlab-user-id', $user->getId());
          return $this->postLogin($request, $user, $registration);
      }
code: public function login (Request $request, User $user, $registration = false)
      {
          // Check for email validation
          if ($this->requiresEmailValidation()) {
              if (!$user->isEmailVerified()) {
                  $request->getSession()->set ('catlab-non-verified-user-id', $user->getId());
                  return Response::redirect(URLBuilder::getURL($this->routepath . '/notverified'));
              }
          }
  
          $request->getSession()->set('catlab-user-id', $user->getId());
          return $this->postLogin($request, $user, $registration);
      }
code_tokens: public function login ( Request $ request , User $ user , $ registration = false ) { // Check for email validation if ( $ this -> requiresEmailValidation ( ) ) { if ( ! $ user -> isEmailVerified ( ) ) { $ request -> getSession ( ) -> set ( 'catlab-non-verified-user-id' , $ user -> getId ( ) ) ; return Response :: redirect ( URLBuilder :: getURL ( $ this -> routepath . '/notverified' ) ) ; } } $ request -> getSession ( ) -> set ( 'catlab-user-id' , $ user -> getId ( ) ) ; return $ this -> postLogin ( $ request , $ user , $ registration ) ; }
docstring: Login a specific user
  @param Request $request
  @param User $user
  @param bool $registration
  @return \Neuron\Net\Response
  @throws DataNotSet
docstring_tokens: Login a specific user