UPDATE
cscart_lock_keys
SET
expiry_at = UNIX_TIMESTAMP(NOW()) + 30,
token = 'RInuKNQRhtmX2S8u9NPA4Gz6pRWWGnXYxrb3DCgQDOs='
WHERE
key_id = '74378df5d46129e08475e42db74265840596aba6a13365c0ac335a01372057ea'
AND (
token = 'RInuKNQRhtmX2S8u9NPA4Gz6pRWWGnXYxrb3DCgQDOs='
OR expiry_at <= UNIX_TIMESTAMP(NOW())
)