UPDATE
cscart_lock_keys
SET
expiry_at = UNIX_TIMESTAMP(NOW()) + 30,
token = 'FwvwsQ9r/8la7pznhDiEOvw3FgsmpinC7MEe1mYoHD8='
WHERE
key_id = '1e70a6ea476f65e77f799236476ffefb604c88ca7b92ed9c55233a5d4d544f5f'
AND (
token = 'FwvwsQ9r/8la7pznhDiEOvw3FgsmpinC7MEe1mYoHD8='
OR expiry_at <= UNIX_TIMESTAMP(NOW())
)