fixed error handler looping bug