UPDATE
cscart_lock_keys
SET
expiry_at = UNIX_TIMESTAMP(NOW()) + 30,
token = 'PoGOpiv2aqX7Dl2b7P21LsuSTl8oB4kzKJRcQRdxdKc='
WHERE
key_id = '70280575de79f4503d08b927f33abd60e9634e9964edb627bd841cc7052246b5'
AND (
token = 'PoGOpiv2aqX7Dl2b7P21LsuSTl8oB4kzKJRcQRdxdKc='
OR expiry_at <= UNIX_TIMESTAMP(NOW())
)