anymal-protocol 1.0.41 → 1.0.42

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/dist/index.d.mts CHANGED
@@ -1,4 +1,4 @@
1
- declare function useVerifyAccount(): (pid: string, isCampaign: boolean, dbAuthToken: string, bundlerClient: any, smartAccount: any, accountRewardsContractAddress: `0x${string}`) => Promise<{
1
+ declare function useVerifyAccount(): (pid: string, campaignId: string, dbAuthToken: string, bundlerClient: any, smartAccount: any, accountRewardsContractAddress: `0x${string}`) => Promise<{
2
2
  success: boolean;
3
3
  message: string;
4
4
  }>;
package/dist/index.d.ts CHANGED
@@ -1,4 +1,4 @@
1
- declare function useVerifyAccount(): (pid: string, isCampaign: boolean, dbAuthToken: string, bundlerClient: any, smartAccount: any, accountRewardsContractAddress: `0x${string}`) => Promise<{
1
+ declare function useVerifyAccount(): (pid: string, campaignId: string, dbAuthToken: string, bundlerClient: any, smartAccount: any, accountRewardsContractAddress: `0x${string}`) => Promise<{
2
2
  success: boolean;
3
3
  message: string;
4
4
  }>;
package/dist/index.js CHANGED
@@ -70,7 +70,7 @@ var MARKETPLACE_ABI = [{ "inputs": [{ "internalType": "address", "name": "target
70
70
  // src/utils/account/useVerifyAccount.ts
71
71
  function useVerifyAccount() {
72
72
  return (0, import_react.useCallback)(
73
- async (pid, isCampaign, dbAuthToken, bundlerClient, smartAccount, accountRewardsContractAddress) => {
73
+ async (pid, campaignId, dbAuthToken, bundlerClient, smartAccount, accountRewardsContractAddress) => {
74
74
  if (!dbAuthToken || !bundlerClient || !smartAccount || !accountRewardsContractAddress || !pid) {
75
75
  return {
76
76
  success: false,
@@ -80,7 +80,7 @@ function useVerifyAccount() {
80
80
  const callData = (0, import_viem.encodeFunctionData)({
81
81
  abi: VERIFY_ACCOUNT_ABI,
82
82
  functionName: "claimRewardByName",
83
- args: [isCampaign ? "petastic-signup-campaign-1" : "default", pid]
83
+ args: [campaignId, pid]
84
84
  });
85
85
  try {
86
86
  const userOpHash = await bundlerClient.sendUserOperation({
package/dist/index.mjs CHANGED
@@ -25,7 +25,7 @@ var MARKETPLACE_ABI = [{ "inputs": [{ "internalType": "address", "name": "target
25
25
  // src/utils/account/useVerifyAccount.ts
26
26
  function useVerifyAccount() {
27
27
  return useCallback(
28
- async (pid, isCampaign, dbAuthToken, bundlerClient, smartAccount, accountRewardsContractAddress) => {
28
+ async (pid, campaignId, dbAuthToken, bundlerClient, smartAccount, accountRewardsContractAddress) => {
29
29
  if (!dbAuthToken || !bundlerClient || !smartAccount || !accountRewardsContractAddress || !pid) {
30
30
  return {
31
31
  success: false,
@@ -35,7 +35,7 @@ function useVerifyAccount() {
35
35
  const callData = encodeFunctionData({
36
36
  abi: VERIFY_ACCOUNT_ABI,
37
37
  functionName: "claimRewardByName",
38
- args: [isCampaign ? "petastic-signup-campaign-1" : "default", pid]
38
+ args: [campaignId, pid]
39
39
  });
40
40
  try {
41
41
  const userOpHash = await bundlerClient.sendUserOperation({
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "anymal-protocol",
3
- "version": "1.0.41",
3
+ "version": "1.0.42",
4
4
  "description": "A React/TypeScript-based utility library for reusable functions and hooks inside of the Anymal Ecosystem.",
5
5
  "main": "dist/index.js",
6
6
  "module": "dist/index.js",