I would move these two lines out of the `try`