Fixed the missing variable declarations on iterators. This makes running the tests in ES6 pass!

Signed-off-by: Alexander Mays <maysale01@gmail.com>
This commit is contained in:
Alexander Mays
2016-02-02 10:03:54 -05:00
parent 477a091f88
commit 52769cce29
3 changed files with 4 additions and 4 deletions

View File

@@ -232,7 +232,7 @@ ExportAdapter.prototype.handleRelationUpdates = function(className,
} }
if (op.__op == 'Batch') { if (op.__op == 'Batch') {
for (x of op.ops) { for (var x of op.ops) {
process(x, key); process(x, key);
} }
} }

View File

@@ -434,7 +434,7 @@ function includePath(config, auth, response, path) {
function findPointers(object, path) { function findPointers(object, path) {
if (object instanceof Array) { if (object instanceof Array) {
var answer = []; var answer = [];
for (x of object) { for (var x of object) {
answer = answer.concat(findPointers(x, path)); answer = answer.concat(findPointers(x, path));
} }
return answer; return answer;

View File

@@ -153,7 +153,7 @@ function normalize(obj) {
return '[' + obj.map(normalize).join(', ') + ']'; return '[' + obj.map(normalize).join(', ') + ']';
} }
var answer = '{'; var answer = '{';
for (key of Object.keys(obj).sort()) { for (var key of Object.keys(obj).sort()) {
answer += key + ': '; answer += key + ': ';
answer += normalize(obj[key]); answer += normalize(obj[key]);
answer += ', '; answer += ', ';
@@ -192,7 +192,7 @@ function mockFacebook() {
function clearData() { function clearData() {
var promises = []; var promises = [];
for (conn in DatabaseAdapter.dbConnections) { for (var conn in DatabaseAdapter.dbConnections) {
promises.push(DatabaseAdapter.dbConnections[conn].deleteEverything()); promises.push(DatabaseAdapter.dbConnections[conn].deleteEverything());
} }
return Promise.all(promises); return Promise.all(promises);