Welcome Guest, Not a member yet? Register   Sign In
Time objects can break session
#3

(This post was last modified: 02-11-2022, 09:41 AM by Jan Zelenka.)

Error
Invalid serialization data for DateTime object
SYSTEMPATH/Session/Session.php at line 1005

Code:
998         if (ENVIRONMENT === 'testing')
999         {
1000             $_SESSION = [];
1001             return;
1002         }
1003
1004         // @codeCoverageIgnoreStart
1005         session_start();
1006         // @codeCoverageIgnoreEnd
1007     }
1008
1009     //--------------------------------------------------------------------
1010
1011     /**
1012      * Takes care of setting the cookie on the client side.

Now this is puzzling. I found this fix:
https://github.com/codeigniter4/CodeIgni...78b1bdc1b3
But when I look at the current code on GitHub, Time::__wakeup() is not there. I added this function to my version of the Time class and so far it seems to be working fine.
Reply


Messages In This Thread
Time objects can break session - by Jan Zelenka - 02-11-2022, 01:03 AM
RE: Time objects can break session - by Jan Zelenka - 02-11-2022, 09:18 AM
RE: Time objects can break session - by kenjis - 02-11-2022, 06:03 PM



Theme © iAndrew 2016 - Forum software by © MyBB