Remove usage of ++ outside of for loops update

The usage of postfix ++ is somewhat obscure in its meaning.  It's better
to be explicit here.
This commit is contained in:
Hornwitser committed 2020-11-07 18:16:24 +01:00
1 parent 3ce32ba870
commit 5337280eec
8 files changed
+21 -14

No files matched your search

+1 -1
View File
@@ -24,7 +24,7 @@ describe("Integration of lib/factorio/export", function() {
// Value is always a string, nearly always truthy
if (!value) {
empty_keys++;
empty_keys += 1;
}
assert.equal(typeof value, "string");
}
+1 -1
View File
@@ -199,7 +199,7 @@ describe("lib/factorio", function() {
} catch (err) { }
if (success) {
validate(modules);
successCount++;
successCount += 1;
}
}
+4 -2
View File
@@ -58,10 +58,12 @@ class MockConnector extends events.EventEmitter {
}
send(type, data) {
let message = { seq: this._seq, type, data };
let seq = this._seq;
this._seq += 1;
let message = { seq, type, data };
this.sentMessages.push(message);
setImmediate(() => this.emit("send", message));
return this._seq++;
return seq;
}
}