UPDATE
cscart_lock_keys
SET
expiry_at = UNIX_TIMESTAMP(NOW()) + 30,
token = 'vpnoCDGruuQGzfqs3jK2He3d3eGazO/NIWXHuvh5ubY='
WHERE
key_id = '064436f144b49c3d2f0834629cc1b5c9fe7b9331fbf068698b4b8ad4918360c2'
AND (
token = 'vpnoCDGruuQGzfqs3jK2He3d3eGazO/NIWXHuvh5ubY='
OR expiry_at <= UNIX_TIMESTAMP(NOW())
)