Skip to content

Commit

Permalink
Simplify logic in storage\session\adapter\Php::key().
Browse files Browse the repository at this point in the history
  • Loading branch information
jperras authored and nateabele committed Mar 30, 2010
1 parent 6e4ab4d commit 4953c38
Showing 1 changed file with 1 addition and 2 deletions.
3 changes: 1 addition & 2 deletions libraries/lithium/storage/session/adapter/Php.php
Original file line number Diff line number Diff line change
Expand Up @@ -105,8 +105,7 @@ public function isStarted() {
* @return mixed Session id, or null if the session has not been started.
*/
public function key() {
$id = session_id();
return ($id === '') ? null : $id;
return session_id() ?: null;
}

/**
Expand Down

0 comments on commit 4953c38

Please sign in to comment.