Przeglądaj źródła

fix(): minor fix for event emitter

Torkel Ödegaard 9 lat temu
rodzic
commit
34cb17546d
1 zmienionych plików z 1 dodań i 1 usunięć
  1. 1 1
      public/app/core/utils/emitter.ts

+ 1 - 1
public/app/core/utils/emitter.ts

@@ -23,7 +23,7 @@ export class Emitter {
     this.emitter.on(name, handler);
 
     if (scope) {
-      scope.$on('$destroy', function() {
+      scope.$on('$destroy', () => {
         this.emitter.off(name, handler);
       });
     }