Skip to content

Commit

Permalink
feat(ui): delete unnecessary contract url computed
Browse files Browse the repository at this point in the history
  • Loading branch information
gabaldon committed Aug 27, 2021
1 parent 0c7705e commit 83258a8
Show file tree
Hide file tree
Showing 2 changed files with 1 addition and 11 deletions.
1 change: 0 additions & 1 deletion packages/api/src/web3Middleware/index.ts
Original file line number Diff line number Diff line change
Expand Up @@ -118,7 +118,6 @@ export class Web3Middleware {
requestId: await feedContract.methods.requestId().call()
}
} catch (err) {
console.log('readContractsState ERROR', err)
throw new Error(`Error reading contract state`)
}
}
Expand Down
11 changes: 1 addition & 10 deletions packages/ui/components/DataFeedDetails.vue
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,7 @@
:title="$t('data_feed_details.contract_address')"
class="contract-container"
>
<a :href="feedAddressUrl" target="_blank" class="contract-address">
<a :href="url" target="_blank" class="contract-address">
{{ feedAddress }}
<font-awesome-icon class="icon" icon="external-link-alt" />
</a>
Expand Down Expand Up @@ -109,15 +109,6 @@ export default {
feedAddress() {
return this.feed ? this.feed.address : ''
},
feedAddressUrl() {
if (this.feed.network === 'conflux') {
return `https://testnet.confluxscan.io/address/${this.feedAddress}`
} else if (this.feed.network === 'mainnet') {
return `https://etherscan.io/address/${this.feedAddress}#code`
} else {
return `https://${this.feed.network}.etherscan.io/address/${this.feedAddress}#code`
}
},
network() {
return this.feed ? this.feed.network.toUpperCase() : ''
},
Expand Down

0 comments on commit 83258a8

Please sign in to comment.