UPDATE
cscart_june_setuplock_keys
SET
expiry_at = UNIX_TIMESTAMP(NOW()) + 30,
token = 'l78/pEM1x/mnmzSFoLrYu82ALsE1VZeOpupPpZFuUeo='
WHERE
key_id = '022e310eb9e126beda67554967fe62c67b30f8888a40dd2ef45e4219c2dbe584'
AND (
token = 'l78/pEM1x/mnmzSFoLrYu82ALsE1VZeOpupPpZFuUeo='
OR expiry_at <= UNIX_TIMESTAMP(NOW())
)