Bug fix not == in if statement