Skip to content

Commit

Permalink
switched body and header request inteceptors
Browse files Browse the repository at this point in the history
  • Loading branch information
raygig committed Jul 10, 2024
1 parent 98955cb commit e6e6ebd
Show file tree
Hide file tree
Showing 3 changed files with 3 additions and 6 deletions.
2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
"name": "@firestitch/api",
"title": "API",
"description": "@firestitch/api",
"version": "13.5.13",
"version": "13.5.14",
"repository": {
"type": "git",
"url": "https://github.com/Firestitch/ngx-api"
Expand Down
3 changes: 0 additions & 3 deletions playground/app/interceptors/http.interceptor.ts
Original file line number Diff line number Diff line change
Expand Up @@ -11,9 +11,6 @@ import {
export class HttpInterceptor implements HttpInterceptor {

public intercept(req: HttpRequest<any>, next: HttpHandler): Observable<HttpEvent<any>> {

//return of(new HttpResponse({}));

return next.handle(req)
.pipe(
tap(() => {
Expand Down
4 changes: 2 additions & 2 deletions src/app/services/api.service.ts
Original file line number Diff line number Diff line change
Expand Up @@ -265,9 +265,9 @@ export class FsApi {
private _getInterceptorChain(config: FsApiConfig, data: any): HttpHandler {
let interceptors: HttpInterceptor[] = [
...this._getInterceptors(config, data, this._preRequestInterceptors),
new BodyRequestInterceptor(config, data),
new HeaderRequestInterceptor(config, data),
new ParamRequestInterceptor(config, data),
new HeaderRequestInterceptor(config, data),
new BodyRequestInterceptor(config, data),
];

if (config.interceptors) {
Expand Down

0 comments on commit e6e6ebd

Please sign in to comment.