The contents of this `try` could probably go in its own method.