Prevent Exceptions when running error checkers with alerts or closed windows