src/Web/Sessions/CachedSessionHandler.php
protected function packRecord($data) {
        $record = [];
        $dKey = $this->dataKey;
        $tKey = $this->timestampKey;
        if (isset($data[$tKey])) {
            unset($data[$tKey]);
        }
        if (isset($data[$dKey])) {
            $record[$dKey] = $data[$dKey];
        } else {
            $record[$dKey] = $data;
        }
        $record[$this->timestampKey] = time();
        $record[$dKey] = !is_string($record[$dKey])
            ? $this->serializeData($record[$dKey])
            : $record[$dKey];
        return $record;
    }
protected function packRecord($data) {
        $record = [];
        $dKey = $this->dataKey;
        $tKey = $this->timestampKey;
        if (isset($data[$tKey])) {
            unset($data[$tKey]);
        }
        if (isset($data[$dKey])) {
            $record[$dKey] = $data[$dKey];
        } else {
            $record[$dKey] = $data;
        }
        $record[$this->timestampKey] = time();
        $record[$dKey] = !is_string($record[$dKey])
            ? $this->serializeData($record[$dKey])
            : $record[$dKey];
        return $record;
    }
Pack record
@param array $data
@return array