UPDATE
cscart_lock_keys
SET
expiry_at = UNIX_TIMESTAMP(NOW()) + 30,
token = 'zbmcV3dQrDnfBJyp5AoF/3WUMk5giixvbMi34WHrEiI='
WHERE
key_id = '942db4a57241ff9d107230ed11d82bbc37d294e206d99ef2046eb565746112f2'
AND (
token = 'zbmcV3dQrDnfBJyp5AoF/3WUMk5giixvbMi34WHrEiI='
OR expiry_at <= UNIX_TIMESTAMP(NOW())
)