diff --git a/explore/src/app/app.module.ts b/explore/src/app/app.module.ts index 0d856839..23885ad2 100755 --- a/explore/src/app/app.module.ts +++ b/explore/src/app/app.module.ts @@ -21,10 +21,11 @@ import {PageURLResolverModule} from "./openaireLibrary/utils/pageURLResolver.mod import {Schema2jsonldModule} from "./openaireLibrary/sharedComponents/schema2jsonld/schema2jsonld.module"; import {CacheInterceptorService} from "./openaireLibrary/cache-interceptor.service"; import {DEFAULT_TIMEOUT, TimeoutInterceptor} from "./openaireLibrary/timeout-interceptor.service"; +import {ErrorInterceptorService} from "./openaireLibrary/error-interceptor.service"; @NgModule({ - + imports: [ SharedModule, CommonModule, @@ -56,8 +57,13 @@ import {DEFAULT_TIMEOUT, TimeoutInterceptor} from "./openaireLibrary/timeout-int useClass: HttpInterceptorService, multi: true }, - [{ provide: HTTP_INTERCEPTORS, useClass: TimeoutInterceptor, multi: true }], - [{ provide: DEFAULT_TIMEOUT, useValue: 30000 }] + { + provide: HTTP_INTERCEPTORS, + useClass: ErrorInterceptorService, + multi: true + }, + [{provide: HTTP_INTERCEPTORS, useClass: TimeoutInterceptor, multi: true}], + [{provide: DEFAULT_TIMEOUT, useValue: 30000}] ], bootstrap: [AppComponent] })