removing unwanted try-catch block