diff --git a/lib/modules/ens/contracts/ENSRegistry.sol b/lib/modules/ens/contracts/ENSRegistry.sol index 37917c81..c843586c 100644 --- a/lib/modules/ens/contracts/ENSRegistry.sol +++ b/lib/modules/ens/contracts/ENSRegistry.sol @@ -44,7 +44,7 @@ contract ENSRegistry is ENS { * @param owner The address of the new owner. */ function setSubnodeOwner(bytes32 node, bytes32 label, address owner) public only_owner(node, owner) { - var subnode = keccak256(node, label); + var subnode = sha3(node, label); NewOwner(node, label, owner); records[subnode].owner = owner; } diff --git a/lib/modules/ens/index.js b/lib/modules/ens/index.js index ab661d5a..02259cdd 100644 --- a/lib/modules/ens/index.js +++ b/lib/modules/ens/index.js @@ -7,6 +7,7 @@ const reverseAddrSuffix = '.addr.reverse'; class ENS { constructor(embark, _options) { + this.env = embark.env; this.logger = embark.logger; this.events = embark.events; this.namesConfig = embark.config.namesystemConfig; @@ -50,7 +51,7 @@ class ENS { }; self.addSetProvider(config); - if (!self.registration || !self.registration.subdomains || !Object.keys(self.registration.subdomains).length) { + if (!self.env === 'development' || !self.registration || !self.registration.subdomains || !Object.keys(self.registration.subdomains).length) { return cb(); } self.registerConfigDomains(config, cb);