Skip to content

Commit

Permalink
fix(network): change mumbai to amoy (#11)
Browse files Browse the repository at this point in the history
Co-authored-by: Kay <kehiiiiya@gmail.com>
  • Loading branch information
ZigBalthazar and kehiy authored Apr 19, 2024
1 parent 32d3095 commit 7259c35
Show file tree
Hide file tree
Showing 3 changed files with 6 additions and 5 deletions.
4 changes: 3 additions & 1 deletion .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -15,4 +15,6 @@ node_modules

.openzeppelin

/src/types
/src/types

output
2 changes: 1 addition & 1 deletion hardhat.config.ts
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,7 @@ if (!process.env.CI) {
hardhat: {
allowUnlimitedContractSize: false,
},
mumbai: {
amoy: {
url: RPC,
accounts: [account],
},
Expand Down
5 changes: 2 additions & 3 deletions utils/file.ts
Original file line number Diff line number Diff line change
Expand Up @@ -4,12 +4,12 @@ import path from "path" // Import the 'path' module
export type Addresses = {
proxy?: string
latestVersion?: string
admin?:string
admin?: string
}
const filePath = path.join(__dirname, "..", "output", "addresses.json")

export function loadAddresses(): Addresses {
let output: Addresses = {}
const filePath = path.join(__dirname, "output", "addresses.json")
if (fs.existsSync(filePath)) {
output = JSON.parse(fs.readFileSync(filePath, "utf8"))
} else {
Expand All @@ -21,7 +21,6 @@ export function loadAddresses(): Addresses {
}

export function saveAddresses(content: Addresses): void {
const filePath = path.join(__dirname, "output", "addresses.json")
if (!fs.existsSync(filePath)) {
const outputDir = path.join(__dirname, "output")
if (!fs.existsSync(outputDir)) fs.mkdirSync(outputDir)
Expand Down

0 comments on commit 7259c35

Please sign in to comment.