private function payloadExists(): bool
{ return EntityDefinitionQueryHelper::
columnExists($this->connection, 'cart', 'payload'
);
} private function serializeCart(Cart
$cart, bool
$payloadExists): string
{ $errors =
$cart->
getErrors();
$data =
$cart->
getData();
$cart->
setErrors(new ErrorCollection());
$cart->
setData(null
);
$this->cartSerializationCleaner->
cleanupCart($cart);
// @deprecated tag:v6.6.0 - remove else part
if ($payloadExists) { $serialized =
$this->compress ? CacheValueCompressor::
compress($cart) :
serialize($cart);
} else { $serialized =
serialize($cart);
}