mirror of https://github.com/embarklabs/embark.git
Address PR feedback
This commit is contained in:
parent
dd8c6b9a35
commit
7e12f80eda
|
@ -286,9 +286,7 @@ class EmbarkController {
|
|||
engine.startService("namingSystem");
|
||||
engine.startService("console");
|
||||
engine.startService("pluginCommand");
|
||||
engine.events.on('check:backOnline:Ethereum', function () {
|
||||
callback();
|
||||
});
|
||||
engine.events.on('check:backOnline:Ethereum', () => callback());
|
||||
},
|
||||
function ipcConnect(callback) {
|
||||
// Do specific work in case we are connected to a socket:
|
||||
|
|
|
@ -29,8 +29,12 @@ const DEFAULT_ENS_CONTRACTS_CONFIG = {
|
|||
}
|
||||
};
|
||||
|
||||
const MAINNET_ID = '1';
|
||||
const ROPSTEN_ID = '3';
|
||||
const RINKEBY_ID = '4';
|
||||
|
||||
const ENS_CONTRACTS_CONFIG = {
|
||||
"1": {
|
||||
[MAINNET_ID]: {
|
||||
"contracts": {
|
||||
"ENSRegistry": {
|
||||
"address": "0x314159265dd8dbb310642f98f50c066173c1259b",
|
||||
|
@ -44,7 +48,7 @@ const ENS_CONTRACTS_CONFIG = {
|
|||
}
|
||||
}
|
||||
},
|
||||
"3": {
|
||||
[ROPSTEN_ID]: {
|
||||
"contracts": {
|
||||
"ENSRegistry": {
|
||||
"address": "0x112234455c3a32fd11230c42e7bccd4a84e02010",
|
||||
|
@ -58,7 +62,7 @@ const ENS_CONTRACTS_CONFIG = {
|
|||
}
|
||||
}
|
||||
},
|
||||
"4": {
|
||||
[RINKEBY_ID]: {
|
||||
"contracts": {
|
||||
"ENSRegistry": {
|
||||
"address": "0xe7410170f87102DF0055eB195163A03B7F2Bff4A",
|
||||
|
@ -143,9 +147,9 @@ class ENS {
|
|||
}
|
||||
|
||||
self.events.request('blockchain:networkId', (networkId) => {
|
||||
const isKnownNetworks = Object.keys(ENS_CONTRACTS_CONFIG).includes(networkId);
|
||||
const isKnownNetwork = Object.keys(ENS_CONTRACTS_CONFIG).includes(networkId);
|
||||
const shouldRegisterSubdomain = self.registration && self.registration.subdomains && Object.keys(self.registration.subdomains).length;
|
||||
if (isKnownNetworks || !shouldRegisterSubdomain) {
|
||||
if (isKnownNetwork || !shouldRegisterSubdomain) {
|
||||
return cb();
|
||||
}
|
||||
self.registerConfigDomains(config, cb);
|
||||
|
|
Loading…
Reference in New Issue