Skip to content
This repository has been archived by the owner on May 30, 2018. It is now read-only.

Commit

Permalink
Safer 'Sessions' system, now creates them if the API requires it and …
Browse files Browse the repository at this point in the history
…doesn't exists :P
  • Loading branch information
iksaku committed Dec 30, 2014
1 parent 187d288 commit 9a1b7f9
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions src/EssentialsPE/Loader.php
Original file line number Diff line number Diff line change
Expand Up @@ -471,11 +471,11 @@ public function removeSession(Player $player){

/**
* @param Player $player
* @return bool|BaseSession
* @return BaseSession
*/
public function getSession(Player $player){
if(!$this->sessionExists($player)){
return false;
$this->createSession($player);
}
return $this->sessions[$player->getName()];
}
Expand Down

0 comments on commit 9a1b7f9

Please sign in to comment.