Skip to content

Commit

Permalink
adapt changes from the sdk
Browse files Browse the repository at this point in the history
  • Loading branch information
H34D committed Nov 14, 2022
1 parent ed26e4a commit 0c257ff
Show file tree
Hide file tree
Showing 6 changed files with 15 additions and 21 deletions.
2 changes: 1 addition & 1 deletion package.json
Expand Up @@ -16,7 +16,7 @@
"doc": "ts-node ./src/doc.ts"
},
"dependencies": {
"@masa-finance/masa-sdk": "^0.4.6",
"@masa-finance/masa-sdk": "^0.5.0",
"@types/clear": "^0.1.2",
"@types/figlet": "^1.5.5",
"chalk": "~4.1.2",
Expand Down
8 changes: 4 additions & 4 deletions src/commands/2fa/info.ts
@@ -1,13 +1,13 @@
import { masa } from "../../helpers";

export const info = async () => {
const identityContracts = await masa.contracts.loadIdentityContracts();

console.log("Soulbound 2FA");
console.log(`Contract Address: '${identityContracts.Soulbound2FA.address}'`);
console.log(
`Contract Address: '${masa.contracts.identity.Soulbound2FA.address}'`
);
console.log(
`Total 2FAs: ${(
await identityContracts.Soulbound2FA.totalSupply()
await masa.contracts.identity.Soulbound2FA.totalSupply()
).toNumber()}`
);
};
6 changes: 2 additions & 4 deletions src/commands/credit-score/info.ts
@@ -1,15 +1,13 @@
import { masa } from "../../helpers";

export const info = async () => {
const identityContracts = await masa.contracts.loadIdentityContracts();

console.log("Soulbound Credit Report");
console.log(
`Contract Address: '${identityContracts.SoulboundCreditReportContract.address}'`
`Contract Address: '${masa.contracts.identity.SoulboundCreditReportContract.address}'`
);
console.log(
`Total Credit Reports: ${(
await identityContracts.SoulboundCreditReportContract.totalSupply()
await masa.contracts.identity.SoulboundCreditReportContract.totalSupply()
).toNumber()}`
);
};
6 changes: 2 additions & 4 deletions src/commands/identity/info.ts
@@ -1,15 +1,13 @@
import { masa } from "../../helpers";

export const info = async () => {
const identityContracts = await masa.contracts.loadIdentityContracts();

console.log("Soulbound Identity");
console.log(
`Contract Address: '${identityContracts.SoulboundIdentityContract.address}'`
`Contract Address: '${masa.contracts.identity.SoulboundIdentityContract.address}'`
);
console.log(
`Total Identities: ${(
await identityContracts.SoulboundIdentityContract.totalSupply()
await masa.contracts.identity.SoulboundIdentityContract.totalSupply()
).toNumber()}`
);
};
6 changes: 2 additions & 4 deletions src/commands/soul-name/info.ts
@@ -1,15 +1,13 @@
import { masa } from "../../helpers";

export const info = async () => {
const identityContracts = await masa.contracts.loadIdentityContracts();

console.log("Soul Name");
console.log(
`Contract Address: '${identityContracts.SoulNameContract.address}'`
`Contract Address: '${masa.contracts.identity.SoulNameContract.address}'`
);
console.log(
`Total Soul Names: ${(
await identityContracts.SoulNameContract.totalSupply()
await masa.contracts.identity.SoulNameContract.totalSupply()
).toNumber()}`
);
};
8 changes: 4 additions & 4 deletions yarn.lock
Expand Up @@ -385,10 +385,10 @@
dependencies:
ethers "^5.6.9"

"@masa-finance/masa-sdk@^0.4.6":
version "0.4.6"
resolved "https://registry.yarnpkg.com/@masa-finance/masa-sdk/-/masa-sdk-0.4.6.tgz#995e0a3315bc99bf924560696f911b17f119819d"
integrity sha512-6XveGjvDNHeo+ZJiBupyUkkfZZnTLGJOuxs2vNlHd90keF9m4d+HDZcF152Vq40VZS/rS3dCm48znYBlTtnmvQ==
"@masa-finance/masa-sdk@^0.5.0":
version "0.5.0"
resolved "https://registry.yarnpkg.com/@masa-finance/masa-sdk/-/masa-sdk-0.5.0.tgz#2992ede73072fd7c54fa9302db9c9378c6e0b203"
integrity sha512-P76UloRrsBT4hNWjm2gEEZ9cztRa6aUwb3i1gLp9YPrPx2aUxcHuM3oCmLw8alQqjxVyNy6JWhCvqzxDlSOcCg==
dependencies:
"@masa-finance/masa-contracts-identity" "^0.4.2"
arweave "^1.11.6"
Expand Down

0 comments on commit 0c257ff

Please sign in to comment.