Skip to content

Commit

Permalink
migrations: fixed read-only call
Browse files Browse the repository at this point in the history
  • Loading branch information
0x31 committed Oct 31, 2019
1 parent 4a06f16 commit 42f1a18
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions migrations/1_darknodes.js
Original file line number Diff line number Diff line change
Expand Up @@ -75,7 +75,7 @@ module.exports = async function (deployer, network, accounts) {
}
const darknodeRegistry = await DarknodeRegistry.at(DarknodeRegistry.address);

const storeOwner = await darknodeRegistryStore.owner();
const storeOwner = await darknodeRegistryStore.owner.call();
if (storeOwner !== DarknodeRegistry.address) {
deployer.logger.log("Linking DarknodeRegistryStore and DarknodeRegistry")
if (storeOwner === accounts[0]) {
Expand Down Expand Up @@ -103,7 +103,7 @@ module.exports = async function (deployer, network, accounts) {
}
const slasher = await DarknodeSlasher.at(DarknodeSlasher.address);

const dnrInSlasher = await slasher.darknodeRegistry();
const dnrInSlasher = await slasher.darknodeRegistry.call();
if (dnrInSlasher.toLowerCase() !== DarknodeRegistry.address.toLowerCase()) {
deployer.logger.log("Updating DNR in Slasher");
await slasher.updateDarknodeRegistry(DarknodeRegistry.address);
Expand Down Expand Up @@ -173,7 +173,7 @@ module.exports = async function (deployer, network, accounts) {
}
}

const dnrInDarknodePayment = await darknodePayment.darknodeRegistry();
const dnrInDarknodePayment = await darknodePayment.darknodeRegistry.call();
if (dnrInDarknodePayment.toLowerCase() !== DarknodeRegistry.address.toLowerCase()) {
deployer.logger.log("Updating DNR in DNP");
await darknodePayment.updateDarknodeRegistry(DarknodeRegistry.address);
Expand Down

0 comments on commit 42f1a18

Please sign in to comment.