small issue in each try statement