feat(http): support request/response promise chaining
myApp.factory('myAroundInterceptor', function($rootScope, $timeout) {
return function(configPromise, responsePromise) {
return {
request: configPromise.then(function(config) {
return config
});
response: responsePromise.then(function(response) {
return 'ha!';
}
});
}
myApp.config(function($httpProvider){
$httpProvider.aroundInterceptors.push('myAroundInterceptor');
}); S
Sylvester Keil committed
4ae46814ff4e7c0bbcdbbefc0a97277283a84065
Parent: 5c735eb
Committed by James deBoer <james@huronbox.com>
on 3/27/2013, 8:13:59 PM