From fa93480d9aadf16698dd3a4439e1870dcb61b5cc Mon Sep 17 00:00:00 2001 From: wanderer Date: Sat, 24 Jan 2015 19:45:53 -0500 Subject: [PATCH] added addressbook --- lib/local.js | 18 ++++++++++++++++++ 1 file changed, 18 insertions(+) create mode 100644 lib/local.js diff --git a/lib/local.js b/lib/local.js new file mode 100644 index 000000000..30cd14df2 --- /dev/null +++ b/lib/local.js @@ -0,0 +1,18 @@ +var addressName = {"0x12378912345789": "Gav", "0x57835893478594739854": "Jeff"}; +var nameAddress = {}; + +for (var prop in addressName) { + if (addressName.hasOwnProperty(prop)) { + nameAddress[addressName[prop]] = prop; + } +} + +var local = { + addressBook:{ + byName: addressName, + byAddress: nameAddress + } +}; + +if (typeof(module) !== "undefined") + module.exports = local;