Преглед на файлове

style: use for loops over _.each in typescript

bergquist преди 8 години
родител
ревизия
9ed1d12cc0
променени са 1 файла, в които са добавени 4 реда и са изтрити 4 реда
  1. 4 4
      public/app/core/services/keybindingSrv.ts

+ 4 - 4
public/app/core/services/keybindingSrv.ts

@@ -189,16 +189,16 @@ export class KeybindingSrv {
 
 
     // collapse all rows
     // collapse all rows
     this.bind('d C', () => {
     this.bind('d C', () => {
-      _.each(dashboard.rows, function(row) {
+      for (let row of dashboard.rows) {
         row.collapse = true;
         row.collapse = true;
-      });
+      }
     });
     });
 
 
     // expand all rows
     // expand all rows
     this.bind('d E', () => {
     this.bind('d E', () => {
-      _.each(dashboard.rows, function(row) {
+      for (let row of dashboard.rows) {
         row.collapse = false;
         row.collapse = false;
-      });
+      }
     });
     });
 
 
     this.bind('d r', () => {
     this.bind('d r', () => {