UPDATE 
  cscart_lock_keys 
SET 
  expiry_at = UNIX_TIMESTAMP(NOW()) + 30, 
  token = 'd/nLfR5XSuqdnBOi3xtgPu3USZ2puzszOdm3lGbeCeA=' 
WHERE 
  key_id = '4948adfdf9434e3c9f8acfc665b648e316e3620fb0d32fee529877d0a1e950cd' 
  AND (
    token = 'd/nLfR5XSuqdnBOi3xtgPu3USZ2puzszOdm3lGbeCeA=' 
    OR expiry_at <= UNIX_TIMESTAMP(NOW())
  )

Query time 0.00050