UPDATE
cscart_lock_keys
SET
expiry_at = UNIX_TIMESTAMP(NOW()) + 30,
token = 'c/qLWS5m42LkZZJUt7ImxiXvQmFX+kRNpE26Nz0IoGI='
WHERE
key_id = '267b5181b9207216f217e92c7fc308a7cf185c3f4572b3439157d14fdad8d6c8'
AND (
token = 'c/qLWS5m42LkZZJUt7ImxiXvQmFX+kRNpE26Nz0IoGI='
OR expiry_at <= UNIX_TIMESTAMP(NOW())
)