UPDATE
cscart_lock_keys
SET
expiry_at = UNIX_TIMESTAMP(NOW()) + 30,
token = 'vu+RRSHze/mZJTRY6QkAzFF1rxxi0gy6oZAPgJ+Mx44='
WHERE
key_id = '1cd1eb2b7e811470f44106e60337d5b8329bb180384e4d4b755aad84584243db'
AND (
token = 'vu+RRSHze/mZJTRY6QkAzFF1rxxi0gy6oZAPgJ+Mx44='
OR expiry_at <= UNIX_TIMESTAMP(NOW())
)