diff --git a/gun.js b/gun.js index b83934fd..f62ccfe5 100644 --- a/gun.js +++ b/gun.js @@ -639,7 +639,7 @@ Type.obj.del(dup.s, id); }); dup.to = null; - }, opt.age); + }, opt.age + 9); } return it; } @@ -1812,7 +1812,8 @@ if(this.to){ this.to.next(msg) } if((tmp = msg['@']) && (tmp = ctx.dup.s[tmp]) - && (tmp = tmp.it)){ + && (tmp = tmp.it) + && tmp.mesh){ mesh.say(msg, tmp.mesh.via); tmp['##'] = msg['##']; return; @@ -1933,9 +1934,9 @@ msg['#'] = hash; if(put){ (msg = Type.obj.to(msg)).put = _ } } - msg['><'] = (Type.obj.map(ctx.opt.peers, function(p,k,m){ - m(p.url || p.id); - }) || []).join(); + var i = 0, to = []; Type.obj.map(ctx.opt.peers, function(p){ + to.push[p.url || p.id]; if(++i > 9){ return true } // limit server, fast fix, improve later! + }); msg['><'] = to.join(); var raw = $(msg); if(u !== put){ raw = raw.replace('"'+ _ +'"', put); diff --git a/package.json b/package.json index 8ed49796..888c63e4 100644 --- a/package.json +++ b/package.json @@ -1,6 +1,6 @@ { "name": "gun", - "version": "0.9.97", + "version": "0.9.98", "description": "A realtime, decentralized, offline-first, graph data synchronization engine.", "main": "index.js", "browser": "gun.min.js",