Moved try/catch block