fixed error handler provider and unit test