fix connect provider call and lint

Co-authored-by: brunoedcf <brest.dallacosta@outlook.com>
This commit is contained in:
RcleydsonR
2023-01-12 19:47:11 -03:00
parent f8e1b888ba
commit a5d5c0dde3
3 changed files with 85 additions and 92 deletions

View File

@@ -3,7 +3,7 @@ import { storeToRefs } from "pinia";
import { useEtherStore } from "../store/ether";
import { ref } from "vue";
import { NetworkEnum } from "@/model/NetworkEnum";
import blockchain from "../utils/blockchain";
import { connectProvider } from "../blockchain/provider";
import ethereumImage from "../assets/ethereum.svg";
import polygonImage from "../assets/polygon.svg";
@@ -20,7 +20,7 @@ const currencyMenuHoverToggle = ref<boolean>(false);
//Methods
const connectMetaMask = () => {
blockchain.connectProvider();
connectProvider();
};
const formatWalletAddress = (): string => {
@@ -52,7 +52,7 @@ const getNetworkImage = (networkName: NetworkEnum) => {
let validImages = {
Ethereum: ethereumImage,
Polygon: polygonImage,
Localhost: ethereumImage
Localhost: ethereumImage,
};
return validImages[networkName];