mirror of https://github.com/embarklabs/embark.git
small correction
Signed-off-by: VoR0220 <catalanor0220@gmail.com>
This commit is contained in:
parent
5e7cd6a88b
commit
93feea7c6d
|
@ -173,7 +173,7 @@ __embarkENS.resolve = function (name) {
|
||||||
}).then((addr) => {
|
}).then((addr) => {
|
||||||
return addr;
|
return addr;
|
||||||
}).catch((err) => {
|
}).catch((err) => {
|
||||||
if (err == 'Couldn\'t decode addr from ABI: 0x') {
|
if (err == 'Error: Couldn\'t decode address from ABI: 0x') {
|
||||||
console.log(name + " is not registered");
|
console.log(name + " is not registered");
|
||||||
return "0x";
|
return "0x";
|
||||||
}
|
}
|
||||||
|
@ -196,7 +196,7 @@ __embarkENS.lookup = function (address) {
|
||||||
let resolverContract = new EmbarkJS.Contract({abi: self.resolverInterface, address: resolverAddress});
|
let resolverContract = new EmbarkJS.Contract({abi: self.resolverInterface, address: resolverAddress});
|
||||||
return resolverContract.methods.name(node).call();
|
return resolverContract.methods.name(node).call();
|
||||||
}).catch((err) => {
|
}).catch((err) => {
|
||||||
if (err == 'ERROR: The returned value is not a convertible string: 0x0') {
|
if (err == 'ERROR: The returned value is not a convertible string: 0x0' || err == 'Error: Couldn\'t decode address from ABI: 0x') {
|
||||||
console.log('Address does not resolve to name. Try syncing chain.');
|
console.log('Address does not resolve to name. Try syncing chain.');
|
||||||
return "";
|
return "";
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in New Issue