refactored toIndigo filter, fixed logic error, but still not working