jmathai / epiphany

A micro PHP framework that's fast, easy, clean and RESTful. The framework does not do a lot of magic under the hood. It is, by design, very simple and very powerful.
https://github.com/jmathai/epiphany
Other
686 stars 139 forks source link

use a session manager without calling employ() #96

Open kgustine opened 9 years ago

kgustine commented 9 years ago

Warning: array_shift() expects parameter 1 to be array, null given in EpiSession.php on line 58

If you initialize one, and only one, of the session implementations, you should not have to call employ().

Epi::init('session-apc'); getSession()->set('this','that');

that code would generate a warning because employ is called without an argument so it returns null. array_shift() is then called on $employ which causes the warning. I think this could be cleaned up more, but this is a quick fix.