Skip to content
This repository has been archived by the owner on Dec 12, 2018. It is now read-only.

Commit

Permalink
> modified: es6/zil/index.js
Browse files Browse the repository at this point in the history
>	modified:   lib/zil/index.js
>	modified:   package.json
  • Loading branch information
CapCap_ghostcorn authored and CapCap_ghostcorn committed Aug 28, 2018
1 parent a5f17af commit 59c8fd6
Show file tree
Hide file tree
Showing 3 changed files with 14 additions and 15 deletions.
12 changes: 6 additions & 6 deletions es6/zil/index.js
Original file line number Diff line number Diff line change
Expand Up @@ -26,16 +26,16 @@ const mapPropertyToObjects = (main) => {
const zilProperty = new Property(data)
const zilName = data.name
zilProperty.setMessanger(main.messanger)
const asyncGetterName = (getName) => {
return `get${getName.charAt(0).toUpperCase()}${getName.slice(1)}`
}
// const asyncGetterName = (getName) => {
// return `get${getName.charAt(0).toUpperCase()}${getName.slice(1)}`
// }
const zilObject = {
get: zilProperty.propertyBuilder(),
enumerable: true
}
const newZilObject = {}
newZilObject[asyncGetterName(zilName)] = zilProperty.propertyBuilder()
Object.assign(main, newZilObject)
// const newZilObject = {}
// newZilObject[asyncGetterName(zilName)] = zilProperty.propertyBuilder()
// Object.assign(main, newZilObject)
return Object.defineProperty(main, zilName, zilObject)
})
}
Expand Down
15 changes: 7 additions & 8 deletions lib/zil/index.js
Original file line number Diff line number Diff line change
Expand Up @@ -60,17 +60,16 @@ var mapPropertyToObjects = function mapPropertyToObjects(main) {
var zilProperty = new _property2.default(data);
var zilName = data.name;
zilProperty.setMessanger(main.messanger);
var asyncGetterName = function asyncGetterName(getName) {
return 'get' + getName.charAt(0).toUpperCase() + getName.slice(1);
};
// const asyncGetterName = (getName) => {
// return `get${getName.charAt(0).toUpperCase()}${getName.slice(1)}`
// }
var zilObject = {
get: zilProperty.propertyBuilder(),
enumerable: true
};
var newZilObject = {};
newZilObject[asyncGetterName(zilName)] = zilProperty.propertyBuilder();
(0, _assign2.default)(main, newZilObject);
return (0, _defineProperty2.default)(main, zilName, zilObject);
// const newZilObject = {}
// newZilObject[asyncGetterName(zilName)] = zilProperty.propertyBuilder()
// Object.assign(main, newZilObject)
};return (0, _defineProperty2.default)(main, zilName, zilObject);
});
};

Expand Down
2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "webz.js",
"version": "0.0.24",
"version": "0.0.25",
"description": "Zilliqa Javascript Libraries",
"main": "lib/index.js",
"browser": "dist/Webz.browser.js",
Expand Down

0 comments on commit 59c8fd6

Please sign in to comment.