added string messages to if statements