fixing erroneous outcomes