ErrorHandler in Nativescript - Help


I am implementing an ErrorHandler to control my requests to my api, but when I create it and registered it in the app.module does not detect me. I was reading that nativescript pulls an ErrorHandler by default, as I do to create a custom ErrorHandler for my requests. Greetings and thanks.

   handleError(errorResponse: HttpErrorResponse | any) {


        if (errorResponse instanceof Response) {

          console.log("ERROR DE HANDLER: ", errorResponse);

      goToLogin(): void {
        const router = this.injector.get(Router);



Not sure, but this GitHub issue might help?