diff --git a/src/main/webapp/app/entities/categoria/delete/categoria-delete-dialog.component.ts b/src/main/webapp/app/entities/categoria/delete/categoria-delete-dialog.component.ts index 14225df..bf4e321 100644 --- a/src/main/webapp/app/entities/categoria/delete/categoria-delete-dialog.component.ts +++ b/src/main/webapp/app/entities/categoria/delete/categoria-delete-dialog.component.ts @@ -26,7 +26,6 @@ export class CategoriaDeleteDialogComponent { } confirmDelete(categoria: ICategoria): void { - this.ensureNulaExists(); const categoriaNula = new Categoria(0, 'Otra', EstadoCategoria.ACTIVE); this.getEncuestas(categoria); if (this.encuestas) { @@ -40,15 +39,6 @@ export class CategoriaDeleteDialogComponent { this.activeModal.close('deleted'); }); } - ensureNulaExists(): void { - const categoriaNula = new Categoria(0, 'Otra', EstadoCategoria.ACTIVE); - const categoria = this.categoriaService.find(0); - if (categoria) { - this.categoriaService.update(categoriaNula); - } else { - this.categoriaService.create(categoriaNula); - } - } protected getEncuestas(categoria: ICategoria): void { this.encuestaService.query().subscribe(res => {