Add explicit message field for locally_echoed.

We now set locally_echoed to true for messages that are
locally echoed, and we change some of our code to look
for this flag.
This commit is contained in:
Steve Howell
2017-07-17 10:52:57 -04:00
committed by Tim Abbott
parent fca158e387
commit 0e25055c1d
10 changed files with 23 additions and 17 deletions

View File

@@ -11,7 +11,7 @@ function batched_updater(flag, op, immediate) {
function server_request() {
// Wait for server IDs before sending flags
var real_msgs = _.filter(queue, function (msg) {
return msg.local_id === undefined;
return !msg.locally_echoed;
});
var real_msg_ids = _.map(real_msgs, function (msg) {
return msg.id;