UPDATE 
  cscart_lock_keys 
SET 
  expiry_at = UNIX_TIMESTAMP(NOW()) + 30, 
  token = 'WHWIAVoMkRSON7Xs1vkOyZoopZjF9XlIy00yVqHQ86Y=' 
WHERE 
  key_id = '53ab84281eb3d3f44d110ab929a7cf57ec55302ffc20d50029732ef5fd969c34' 
  AND (
    token = 'WHWIAVoMkRSON7Xs1vkOyZoopZjF9XlIy00yVqHQ86Y=' 
    OR expiry_at <= UNIX_TIMESTAMP(NOW())
  )

Query time 0.00049