trying to fix if statements