allow custom error callback when response not 200