UPDATE
cscart_lock_keys
SET
expiry_at = UNIX_TIMESTAMP(NOW()) + 30,
token = 'rHXI3HgMzmXGbPyMeSxd9/KdLb/XLJ41wEV273uBmSo='
WHERE
key_id = '19ee3bdfe6098f3c75f4cd3617cff2ce3326b17a3f2cd302152f3531d788260d'
AND (
token = 'rHXI3HgMzmXGbPyMeSxd9/KdLb/XLJ41wEV273uBmSo='
OR expiry_at <= UNIX_TIMESTAMP(NOW())
)