diff --git a/src/app/core/services/api.service.ts b/src/app/core/services/api.service.ts index 16b03466..4eab0176 100644 --- a/src/app/core/services/api.service.ts +++ b/src/app/core/services/api.service.ts @@ -96,13 +96,12 @@ export class ApiService { console.log('Error', error.message); } console.log(error.config); - this.loaderService.setStatus(false); + // this.loaderService.setStatus(false); } public async createPoll(poll: Poll): Promise { // this.loaderService.setStatus(true); console.log('createPoll config', poll); - this.loaderService.setStatus(true); return this.axiosInstance.post( `${this.baseHref}${currentApiRoutes['api_new_poll']}`, poll, @@ -295,17 +294,18 @@ export class ApiService { ApiService.handleError(error); } } + ///////////////////// // PRIVATE METHODS // ///////////////////// public async sendEmailToUserOfItsPollsList(email: string): Promise { - if (this.loaderService.isLoading) { - return; - } + // if (this.loaderService.isLoading) { + // return; + // } // If user is not authenticated: the list of polls is send to user's email by the backend. try { - this.loaderService.setStatus(false); + // this.loaderService.setStatus(false); await this.axiosInstance.get( `${this.usersEndpoint}/${email}${this.usersPollsEndpoint}${this.usersPollsSendEmailEndpoint}` );