try-catch block added