UPDATE
cscart_lock_keys
SET
expiry_at = UNIX_TIMESTAMP(NOW()) + 30,
token = 'OM3Iq/1hTD7cz2/FX0agaalfA3r+eMTKd38Ef6zKnNA='
WHERE
key_id = '27a52618e6db995c073fdea6fe5187d854e83391cf3ef87b6f05063cdb2419e7'
AND (
token = 'OM3Iq/1hTD7cz2/FX0agaalfA3r+eMTKd38Ef6zKnNA='
OR expiry_at <= UNIX_TIMESTAMP(NOW())
)