Added if-else statement