ng-http-interceptor
Version:
> Http Interceptor library for Angular
21 lines • 485 B
JavaScript
/**
* @fileoverview added by tsickle
* @suppress {checkTypes} checked by tsc
*/
/**
* \@description
* Gets index of {\@link RequestOptions} in http data array for specified `method`.
* @param {?} method - Http method
* @return {?}
*/
export function getHttpOptionsIdx(method) {
switch (method) {
case 'post':
case 'put':
case 'patch':
return 2;
default:
return 1;
}
}
//# sourceMappingURL=getHttpOptionsIdx.js.map