refactor outside exceptions.