mirror of
https://github.com/cwinfo/hyperboria-peers.git
synced 2024-11-21 17:10:30 +00:00
serialize pub location along with peering data
This commit is contained in:
parent
9084e82644
commit
a0f73582b4
5
index.js
5
index.js
@ -43,7 +43,9 @@ var Fs = require("fs"),
|
|||||||
find(peers, A.slice(1))[name] = {};
|
find(peers, A.slice(1))[name] = {};
|
||||||
walk(A.concat(name));
|
walk(A.concat(name));
|
||||||
} else if (/\.k$/.test(name)) {
|
} else if (/\.k$/.test(name)) {
|
||||||
find(peers, A.slice(1))[name] = read(fullPath);
|
var obj = find(peers, A.slice(1))[name] = read(fullPath);
|
||||||
|
// embed the location in the object
|
||||||
|
obj.location = A.slice(1);
|
||||||
}
|
}
|
||||||
});
|
});
|
||||||
};
|
};
|
||||||
@ -69,7 +71,6 @@ var Fs = require("fs"),
|
|||||||
var path = p.slice(0).concat(k);
|
var path = p.slice(0).concat(k);
|
||||||
|
|
||||||
if (isCred(k)) {
|
if (isCred(k)) {
|
||||||
//console.log(o[k]);
|
|
||||||
L.push(f(o[k], path));
|
L.push(f(o[k], path));
|
||||||
}
|
}
|
||||||
walk(o[k], path, f);
|
walk(o[k], path, f);
|
||||||
|
Loading…
Reference in New Issue
Block a user