Changed if else condition leading to problems