So this is meant as a standard error handling? We don't necessarily need to hook in here to deal with errors as we can pass them to the promise later on.

I think it should be possible not to yield the errorHandler to the doQuery method, but to chain it within the withLoading method, which might be cleaner.

I'll try this first and then merge this PR