src/Security/AuthenticationManager.php
public function authenticate(IUser $user) {
        //set role
        $this->app->user->setAttribute(SessionKeys::UserRole, $user->getRole());
        //store user in session
        $this->app->user->setAttribute(SessionKeys::UserConnected, $user);
    }
public function authenticate(IUser $user) {
        //set role
        $this->app->user->setAttribute(SessionKeys::UserRole, $user->getRole());
        //store user in session
        $this->app->user->setAttribute(SessionKeys::UserConnected, $user);
    }
public function authenticate ( IUser $ user ) { //set role $ this -> app -> user -> setAttribute ( SessionKeys :: UserRole , $ user -> getRole ( ) ) ; //store user in session $ this -> app -> user -> setAttribute ( SessionKeys :: UserConnected , $ user ) ; }
Authenticates a user from the given object.
@param \Puzzlout\Framework\Interfaces\IUser $user
User object holding all the values necessary to connect the user.
Authenticates a user from the given object .