UPDATE 
  cscart_lock_keys 
SET 
  expiry_at = UNIX_TIMESTAMP(NOW()) + 30, 
  token = 'H0R2uCmEqY2vuICOPsEDnGe9nHsu3JLLbt1NEBrAsV0=' 
WHERE 
  key_id = 'e75f9f124198d3e9b86082769f4c7098d07322a8dde0ed21a477fa77ab252c8e' 
  AND (
    token = 'H0R2uCmEqY2vuICOPsEDnGe9nHsu3JLLbt1NEBrAsV0=' 
    OR expiry_at <= UNIX_TIMESTAMP(NOW())
  )

Query time 0.00051