is this return only inside the else condition or it is also for the main method?