Browse Source

Fixes the total byte counter reducer

craigsdennis 9 years ago
parent
commit
1ee80326a2
1 changed files with 3 additions and 1 deletions
  1. 3 1
      back-end/rom_comm.js

+ 3 - 1
back-end/rom_comm.js

@@ -311,7 +311,9 @@ class RomComm extends EventEmitter {
     }
 
     flashSpecifications(specs) {
-        let totalBytes = specs.reduce(() => specs.buffer.length, 0);
+        let totalBytes = specs.reduce((counter, spec) => {
+            counter += spec.buffer.length;
+        }, 0);
         let details = {
             totalFiles: specs.length,
             totalBytes: totalBytes,