comment explaining why an ugly if is needed