$prefetchId =
$this->prefetchId;
$prefetchData =
$this->prefetchData;
unset($this->prefetchId,
$this->prefetchData
);
if ($prefetchId ===
$sessionId || '' ===
$prefetchData) { $this->newSessionId = '' ===
$prefetchData ?
$sessionId : null;
return $prefetchData;
} } $data =
$this->
doRead($sessionId);
$this->newSessionId = '' ===
$data ?
$sessionId : null;
return $data;
} public function write(#[\SensitiveParameter] string $sessionId, string $data): bool
{ // see https://github.com/igbinary/igbinary/issues/146
$this->igbinaryEmptyData ??= \
function_exists('igbinary_serialize'
) ?
igbinary_serialize([]) : '';
if ('' ===
$data ||
$this->igbinaryEmptyData ===
$data) { return $this->
destroy($sessionId);
}