src/Http/Cookie/Drivers/CookieDriver.php
/**
	 * Unserializes data from a string. Throws an exception if the data cannot be read.
	 *
	 * @param string $data
	 * @return mixed
	 * @throws CookieInitializationException
	 */
Unserializes data from a string. Throws an exception if the data cannot be read.
@param string $data
@return mixed
@throws CookieInitializationException
Unserializes data from a string . Throws an exception if the data cannot be read . @param string $data @return mixed @throws CookieInitializationException
private function unserialize($data) {
		if (config('session.serialize', true)) {
			$result = @unserialize($data);
			if ($result === false && $data !== 'b:0;') {
				throw new CookieInitializationException();
			}
			return $result;
		}
		else {
			$result = @json_decode($data, true);
			if (is_null($result)) {
				throw new CookieInitializationException();
			}
			return $result;
		}
	}
private function unserialize ( $ data ) { if ( config ( 'session.serialize' , true ) ) { $ result = @ unserialize ( $ data ) ; if ( $ result === false && $ data !== 'b:0;' ) { throw new CookieInitializationException ( ) ; } return $ result ; } else { $ result = @ json_decode ( $ data , true ) ; if ( is_null ( $ result ) ) { throw new CookieInitializationException ( ) ; } return $ result ; } }
Unserializes data from a string.
Unserializes data from a string .