Making these single line ifs may make this more clear what's happening...but I have no idea