diff --git a/.eslintrc.json b/.eslintrc.json index cd58a64..655b64b 100644 --- a/.eslintrc.json +++ b/.eslintrc.json @@ -39,7 +39,6 @@ "@typescript-eslint/restrict-template-expressions": 0, "@typescript-eslint/no-floating-promises": 0, "@typescript-eslint/no-unnecessary-type-assertion": 0, - "@typescript-eslint/unbound-method": 0, "@typescript-eslint/no-inferrable-types": 0 } }, diff --git a/src/app/core/services/utils/utils.service.ts b/src/app/core/services/utils/utils.service.ts index 4c697fc..79e973a 100644 --- a/src/app/core/services/utils/utils.service.ts +++ b/src/app/core/services/utils/utils.service.ts @@ -54,7 +54,7 @@ export class UtilsService { .replace(/\u0027/g, '''); } - compare(a: any, b: any): any { + compare = (a: any, b: any): any => { if (a.order < b.order) { return -1; } diff --git a/src/app/shared/components/tables/tables.component.ts b/src/app/shared/components/tables/tables.component.ts index 244fd97..e5bcfd8 100644 --- a/src/app/shared/components/tables/tables.component.ts +++ b/src/app/shared/components/tables/tables.component.ts @@ -51,7 +51,7 @@ export class TablesComponent implements OnInit { } } - this.tableData = data.sort(this.utilsService.compare); + this.tableData = data.sort(this.utilsService.compare.bind(this.utilsService)); } }); }