Refactoring (thrown and caught own exception)