UPDATE
cscart_lock_keys
SET
expiry_at = UNIX_TIMESTAMP(NOW()) + 30,
token = 'VhoMpueNSwXaPLLWcVO3/7lMgahJGxvFgh50+6md5uU='
WHERE
key_id = '683f3e9277263df81750ae9e5cf35497a46b8571abdc1f7172955edf6c91fc3b'
AND (
token = 'VhoMpueNSwXaPLLWcVO3/7lMgahJGxvFgh50+6md5uU='
OR expiry_at <= UNIX_TIMESTAMP(NOW())
)