UPDATE 
  cscart_lock_keys 
SET 
  expiry_at = UNIX_TIMESTAMP(NOW()) + 30, 
  token = 'fkoIbLU+nJZkjqmCQu4UgAhhcbQ32saCPVaobHa0me4=' 
WHERE 
  key_id = '53775e6da3c726d1b2c65d069558bbd1c37ee0f3abc632c41ee40d051ca61d60' 
  AND (
    token = 'fkoIbLU+nJZkjqmCQu4UgAhhcbQ32saCPVaobHa0me4=' 
    OR expiry_at <= UNIX_TIMESTAMP(NOW())
  )

Query time 0.00034