Skip to content

Commit

Permalink
added support for base goerli
Browse files Browse the repository at this point in the history
  • Loading branch information
H34D committed Mar 17, 2023
1 parent d1991d9 commit 99d0636
Show file tree
Hide file tree
Showing 9 changed files with 29 additions and 7 deletions.
2 changes: 1 addition & 1 deletion package.json
Expand Up @@ -35,7 +35,7 @@
"author": "Masa Finance",
"license": "MIT",
"dependencies": {
"@masa-finance/masa-contracts-identity": "^1.3.7",
"@masa-finance/masa-contracts-identity": "^1.4.0",
"@masa-finance/masa-token": "^1.0.0",
"arweave": "~1.12.6",
"axios": "^1.3.2",
Expand Down
3 changes: 3 additions & 0 deletions src/contracts/addresses.ts
@@ -1,5 +1,6 @@
import {
alfajores,
basegoerli,
bsc,
bsctest,
celo,
Expand Down Expand Up @@ -38,4 +39,6 @@ export const addresses: Partial<{ [key in NetworkName]: Addresses }> = {
// polygon
mumbai,
polygon,
// base
basegoerli,
};
4 changes: 3 additions & 1 deletion src/contracts/masa-contracts.ts
Expand Up @@ -205,7 +205,9 @@ export class MasaContracts {

// we check that the recovered address is within the authorities
if (!recoveredAddressIsAuthority) {
throw new Error(`${errorMessage}: Authority not allowed!`);
throw new Error(
`${errorMessage}: Authority '${recoveredAddress}' not allowed!`
);
}
}
},
Expand Down
13 changes: 13 additions & 0 deletions src/contracts/networks/base/basegoerli.ts
@@ -0,0 +1,13 @@
import SoulboundIdentity from "@masa-finance/masa-contracts-identity/deployments/basegoerli/SoulboundIdentity.json";
import SoulName from "@masa-finance/masa-contracts-identity/deployments/basegoerli/SoulName.json";
import SoulStore from "@masa-finance/masa-contracts-identity/deployments/basegoerli/SoulStore.json";
import SoulboundGreen from "@masa-finance/masa-contracts-identity/deployments/basegoerli/SoulboundGreen.json";

export const MASA = undefined;
export const USDC = undefined;
export const WETH = undefined;

export const SoulboundIdentityAddress = SoulboundIdentity.address;
export const SoulNameAddress = SoulName.address;
export const SoulStoreAddress = SoulStore.address;
export const SoulboundGreenAddress = SoulboundGreen.address;
1 change: 1 addition & 0 deletions src/contracts/networks/base/index.ts
@@ -0,0 +1 @@
export * as basegoerli from "./basegoerli";
2 changes: 2 additions & 0 deletions src/contracts/networks/index.ts
Expand Up @@ -6,3 +6,5 @@ export * from "./celo";
export * from "./bsc";
// polygon
export * from "./polygon";
// base
export * from "./base";
1 change: 1 addition & 0 deletions src/interface/token/soul-name.ts
Expand Up @@ -10,6 +10,7 @@ export interface Attribute {
export interface ISoulName {
description: "This is a soul name!";
external_url:
| "https://app.getbasecamp.xyz"
| "https://app.prosperity.global"
| "https://testnet.app.masa.finance"
| "https://app.masa.finance";
Expand Down
2 changes: 1 addition & 1 deletion src/utils/clients/masa-client.ts
Expand Up @@ -197,7 +197,7 @@ export class MasaClient {

const storeMetadataResponse = await this._middlewareClient
.post<SoulNameMetadataStoreResult>(
`/storage/store`,
"/storage/store",
{
soulName,
receiver,
Expand Down
8 changes: 4 additions & 4 deletions yarn.lock
Expand Up @@ -440,10 +440,10 @@
"@jridgewell/resolve-uri" "3.1.0"
"@jridgewell/sourcemap-codec" "1.4.14"

"@masa-finance/masa-contracts-identity@^1.3.7":
version "1.3.7"
resolved "https://registry.yarnpkg.com/@masa-finance/masa-contracts-identity/-/masa-contracts-identity-1.3.7.tgz#5ff104b82963001b83383daba99690cb2dc67f90"
integrity sha512-lDTpCQ8pmoHmgs7gxJWKW6XEjbPE5EmsV13fGnMXlsnEkPTSbtcy3HD3EsdNdVQ3QZcR7wqt6fT5AkJmuAMPFQ==
"@masa-finance/masa-contracts-identity@^1.4.0":
version "1.4.0"
resolved "https://registry.yarnpkg.com/@masa-finance/masa-contracts-identity/-/masa-contracts-identity-1.4.0.tgz#4e38f996aeacd1a5092b1746e3daa99b4c0183bc"
integrity sha512-MivrXwKnPPp5BPBmHRtUBZ16farNoP5EgRFhGirfPFD6mZg3jruHYxneOAdkpDPOLV2QcAmwV2Ks6blUmi1xGw==
dependencies:
ethers "~5.7.2"

Expand Down

0 comments on commit 99d0636

Please sign in to comment.