@primuslabs/fund-js-sdk 0.1.17 → 0.1.18

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.js CHANGED
@@ -4140,216 +4140,221 @@ var redPacketIdl_default = {
4140
4140
  },
4141
4141
  {
4142
4142
  code: 6006,
4143
+ name: "InvalidRedId",
4144
+ msg: "Invalid red id"
4145
+ },
4146
+ {
4147
+ code: 6007,
4143
4148
  name: "AmountTooLow",
4144
4149
  msg: "Amount too low"
4145
4150
  },
4146
4151
  {
4147
- code: 6007,
4152
+ code: 6008,
4148
4153
  name: "WrongAmount",
4149
4154
  msg: "Wrong amount"
4150
4155
  },
4151
4156
  {
4152
- code: 6008,
4157
+ code: 6009,
4153
4158
  name: "NoReId",
4154
4159
  msg: "Red envelope ID does not exist"
4155
4160
  },
4156
4161
  {
4157
- code: 6009,
4162
+ code: 6010,
4158
4163
  name: "AllClaimed",
4159
4164
  msg: "All envelopes claimed"
4160
4165
  },
4161
4166
  {
4162
- code: 6010,
4167
+ code: 6011,
4163
4168
  name: "UserIdEmpty",
4164
4169
  msg: "User ID empty"
4165
4170
  },
4166
4171
  {
4167
- code: 6011,
4172
+ code: 6012,
4168
4173
  name: "InvalidUserAddress",
4169
4174
  msg: "Invalid User Address"
4170
4175
  },
4171
4176
  {
4172
- code: 6012,
4177
+ code: 6013,
4173
4178
  name: "AlreadyClaimed",
4174
4179
  msg: "Already claimed"
4175
4180
  },
4176
4181
  {
4177
- code: 6013,
4182
+ code: 6014,
4178
4183
  name: "AmountUnderflow",
4179
4184
  msg: "Amount underflow"
4180
4185
  },
4181
4186
  {
4182
- code: 6014,
4187
+ code: 6015,
4183
4188
  name: "InvalidFeeRecipient",
4184
4189
  msg: "Invalid fee recipient"
4185
4190
  },
4186
4191
  {
4187
- code: 6015,
4192
+ code: 6016,
4188
4193
  name: "InvalidStateAccount",
4189
4194
  msg: "Invalid state account"
4190
4195
  },
4191
4196
  {
4192
- code: 6016,
4197
+ code: 6017,
4193
4198
  name: "RecipientIsZero",
4194
4199
  msg: "Recipient cannot be zero"
4195
4200
  },
4196
4201
  {
4197
- code: 6017,
4202
+ code: 6018,
4198
4203
  name: "InvalidCheckType",
4199
4204
  msg: "Invalid checkType"
4200
4205
  },
4201
4206
  {
4202
- code: 6018,
4207
+ code: 6019,
4203
4208
  name: "InvalidCheckParams",
4204
4209
  msg: "CheckParams decode failed"
4205
4210
  },
4206
4211
  {
4207
- code: 6019,
4212
+ code: 6020,
4208
4213
  name: "NoFund",
4209
4214
  msg: "No fund"
4210
4215
  },
4211
4216
  {
4212
- code: 6020,
4217
+ code: 6021,
4213
4218
  name: "NotOwner",
4214
4219
  msg: "Not owner"
4215
4220
  },
4216
4221
  {
4217
- code: 6021,
4222
+ code: 6022,
4218
4223
  name: "NotExpired",
4219
4224
  msg: "Not expired"
4220
4225
  },
4221
4226
  {
4222
- code: 6022,
4227
+ code: 6023,
4223
4228
  name: "UnsupportedTokenType",
4224
4229
  msg: "Unsupported Token Type"
4225
4230
  },
4226
4231
  {
4227
- code: 6023,
4232
+ code: 6024,
4228
4233
  name: "InsufficientSOL",
4229
4234
  msg: "Insufficient SOL"
4230
4235
  },
4231
4236
  {
4232
- code: 6024,
4237
+ code: 6025,
4233
4238
  name: "WrongTokenMint",
4234
4239
  msg: "Wrong token mint"
4235
4240
  },
4236
4241
  {
4237
- code: 6025,
4242
+ code: 6026,
4238
4243
  name: "DeserializationFailed",
4239
4244
  msg: "Deserialization Failed"
4240
4245
  },
4241
4246
  {
4242
- code: 6026,
4247
+ code: 6027,
4243
4248
  name: "JsonParseError",
4244
4249
  msg: "JSON Parse Error"
4245
4250
  },
4246
4251
  {
4247
- code: 6027,
4252
+ code: 6028,
4248
4253
  name: "ResponseLengthError",
4249
4254
  msg: "response length error"
4250
4255
  },
4251
4256
  {
4252
- code: 6028,
4257
+ code: 6029,
4253
4258
  name: "AttUrlError",
4254
4259
  msg: "att url error"
4255
4260
  },
4256
4261
  {
4257
- code: 6029,
4262
+ code: 6030,
4258
4263
  name: "AttSuffixUrlError",
4259
4264
  msg: "att suffix url error"
4260
4265
  },
4261
4266
  {
4262
- code: 6030,
4267
+ code: 6031,
4263
4268
  name: "JsonPathError",
4264
4269
  msg: "json path error"
4265
4270
  },
4266
4271
  {
4267
- code: 6031,
4272
+ code: 6032,
4268
4273
  name: "UsernameKeyError",
4269
4274
  msg: "username key error"
4270
4275
  },
4271
4276
  {
4272
- code: 6032,
4277
+ code: 6033,
4273
4278
  name: "FollowingError",
4274
4279
  msg: "following error"
4275
4280
  },
4276
4281
  {
4277
- code: 6033,
4282
+ code: 6034,
4278
4283
  name: "FollowingNameError",
4279
4284
  msg: "following name error"
4280
4285
  },
4281
4286
  {
4282
- code: 6034,
4287
+ code: 6035,
4283
4288
  name: "NameOpError",
4284
4289
  msg: "name op error"
4285
4290
  },
4286
4291
  {
4287
- code: 6035,
4292
+ code: 6036,
4288
4293
  name: "AttConditionsError",
4289
4294
  msg: "att conditions error"
4290
4295
  },
4291
4296
  {
4292
- code: 6036,
4297
+ code: 6037,
4293
4298
  name: "TooManyUrls",
4294
4299
  msg: "too many urls"
4295
4300
  },
4296
4301
  {
4297
- code: 6037,
4302
+ code: 6038,
4298
4303
  name: "TooManyResponseresolve",
4299
4304
  msg: "too many responseResolve"
4300
4305
  },
4301
4306
  {
4302
- code: 6038,
4307
+ code: 6039,
4303
4308
  name: "UserNameEmpty",
4304
4309
  msg: "user name empty"
4305
4310
  },
4306
4311
  {
4307
- code: 6039,
4312
+ code: 6040,
4308
4313
  name: "SourceError",
4309
4314
  msg: "source error"
4310
4315
  },
4311
4316
  {
4312
- code: 6040,
4317
+ code: 6041,
4313
4318
  name: "AccountResponseLengthError",
4314
4319
  msg: "account response length error"
4315
4320
  },
4316
4321
  {
4317
- code: 6041,
4322
+ code: 6042,
4318
4323
  name: "TiktokAttUrlError",
4319
4324
  msg: "tiktok att url error"
4320
4325
  },
4321
4326
  {
4322
- code: 6042,
4327
+ code: 6043,
4323
4328
  name: "TiktokJsonPathError",
4324
4329
  msg: "tiktok json path error"
4325
4330
  },
4326
4331
  {
4327
- code: 6043,
4332
+ code: 6044,
4328
4333
  name: "XAttUrlError",
4329
4334
  msg: "x att url error"
4330
4335
  },
4331
4336
  {
4332
- code: 6044,
4337
+ code: 6045,
4333
4338
  name: "XJsonPathError",
4334
4339
  msg: "x json path error"
4335
4340
  },
4336
4341
  {
4337
- code: 6045,
4342
+ code: 6046,
4338
4343
  name: "GoogleAttUrlError",
4339
4344
  msg: "google att url error"
4340
4345
  },
4341
4346
  {
4342
- code: 6046,
4347
+ code: 6047,
4343
4348
  name: "GoogleJsonPathError",
4344
4349
  msg: "google json path error"
4345
4350
  },
4346
4351
  {
4347
- code: 6047,
4352
+ code: 6048,
4348
4353
  name: "XiaohongshuAttUrlError",
4349
4354
  msg: "xiaohongshu att url error"
4350
4355
  },
4351
4356
  {
4352
- code: 6048,
4357
+ code: 6049,
4353
4358
  name: "XiaohongshuJsonPathError",
4354
4359
  msg: "xiaohongshu json path error"
4355
4360
  }
@@ -5793,12 +5798,10 @@ async function reSend({
5793
5798
  space,
5794
5799
  programId: redEnvelopeProgram.programId
5795
5800
  });
5796
- debugger;
5797
5801
  const reRecordDataInitIx = await redEnvelopeProgram.methods.reRecordDataInit().accounts({
5798
5802
  reRecordData: spaceAccount.publicKey,
5799
5803
  sender: userKey
5800
5804
  }).signers([spaceAccount]).instruction();
5801
- debugger;
5802
5805
  const [redEnvelopePda] = getPrimusRedEnvelopePda({ programId: redEnvelopeProgram.programId });
5803
5806
  const redEnvelopeState = await redEnvelopeProgram.account.redEnvelopeState.fetch(redEnvelopePda);
5804
5807
  console.log("idCounter", redEnvelopeState.idCounter.toString());
@@ -5823,7 +5826,6 @@ async function reSend({
5823
5826
  toTokenAccount = to.ata;
5824
5827
  tokenProgram = from.tokenProgramId;
5825
5828
  }
5826
- debugger;
5827
5829
  const reSendIx = await redEnvelopeProgram.methods.reSend(Array.from(reId), tipToken, reSendParam).accounts({
5828
5830
  state: redEnvelopePda,
5829
5831
  reRecord: reRecordPda,
@@ -5892,7 +5894,6 @@ async function reClaim({
5892
5894
  console.log(`attBuffer.length=${attBuffer.length}`);
5893
5895
  let storeInitialized = false;
5894
5896
  let useStoreVersion = false;
5895
- debugger;
5896
5897
  if (reRecord.tokenType == ERC20_TYPE && attBuffer.length > ERC20TOKENATTBUFFERMAXLEN || reRecord.tokenType != ERC20_TYPE && attBuffer.length > NATIVETOKENATTBUFFERMAXLEN) {
5897
5898
  useStoreVersion = true;
5898
5899
  }
@@ -5956,6 +5957,7 @@ async function reClaim({
5956
5957
  }).transaction();
5957
5958
  tx.feePayer = userKey;
5958
5959
  tx.recentBlockhash = (await provider.connection.getLatestBlockhash()).blockhash;
5960
+ console.log("UnSigned tx size:", tx.serialize({ requireAllSignatures: false, verifySignatures: false }).length, "bytes");
5959
5961
  const signedTx = await provider.wallet.signTransaction(tx);
5960
5962
  signatureStr = getTxSigStrFromTx(signedTx);
5961
5963
  const isOnChain = await getTxIsOnChain(signatureStr, provider.connection);
@@ -5964,6 +5966,7 @@ async function reClaim({
5964
5966
  return resolve(signatureStr);
5965
5967
  } else {
5966
5968
  const serializeSignedTx = signedTx.serialize();
5969
+ console.log("Signed tx size:", serializeSignedTx.length, "bytes");
5967
5970
  signatureStr = await provider.connection.sendRawTransaction(serializeSignedTx);
5968
5971
  console.log("reClaim done ", signatureStr);
5969
5972
  return resolve(signatureStr);
@@ -6306,7 +6309,6 @@ var ZktlsSdk = class {
6306
6309
  };
6307
6310
 
6308
6311
  // src/index.ts
6309
- console.log("SUPPORTEDCHAINIDS444", SUPPORTEDCHAINIDS);
6310
6312
  var PrimusFund = class {
6311
6313
  supportedChainIds = SUPPORTEDCHAINIDS;
6312
6314
  supportedSocialPlatforms = SUPPORTEDSOCIALPLATFORMS;
@@ -6351,7 +6353,7 @@ var PrimusFund = class {
6351
6353
  } else if (SUPPORTEDSOLANACHAINIDS.includes(chainId)) {
6352
6354
  this.provider = provider;
6353
6355
  this._fundOnSolanaForRedPacket = new FundOnSolanaForRedPacket();
6354
- this._fundOnSolanaForRedPacket.init(provider, chainId);
6356
+ await this._fundOnSolanaForRedPacket.init(provider, chainId);
6355
6357
  }
6356
6358
  if (appId) {
6357
6359
  this._zkTlsSdk = new ZktlsSdk();
package/dist/index.mjs CHANGED
@@ -4106,216 +4106,221 @@ var redPacketIdl_default = {
4106
4106
  },
4107
4107
  {
4108
4108
  code: 6006,
4109
+ name: "InvalidRedId",
4110
+ msg: "Invalid red id"
4111
+ },
4112
+ {
4113
+ code: 6007,
4109
4114
  name: "AmountTooLow",
4110
4115
  msg: "Amount too low"
4111
4116
  },
4112
4117
  {
4113
- code: 6007,
4118
+ code: 6008,
4114
4119
  name: "WrongAmount",
4115
4120
  msg: "Wrong amount"
4116
4121
  },
4117
4122
  {
4118
- code: 6008,
4123
+ code: 6009,
4119
4124
  name: "NoReId",
4120
4125
  msg: "Red envelope ID does not exist"
4121
4126
  },
4122
4127
  {
4123
- code: 6009,
4128
+ code: 6010,
4124
4129
  name: "AllClaimed",
4125
4130
  msg: "All envelopes claimed"
4126
4131
  },
4127
4132
  {
4128
- code: 6010,
4133
+ code: 6011,
4129
4134
  name: "UserIdEmpty",
4130
4135
  msg: "User ID empty"
4131
4136
  },
4132
4137
  {
4133
- code: 6011,
4138
+ code: 6012,
4134
4139
  name: "InvalidUserAddress",
4135
4140
  msg: "Invalid User Address"
4136
4141
  },
4137
4142
  {
4138
- code: 6012,
4143
+ code: 6013,
4139
4144
  name: "AlreadyClaimed",
4140
4145
  msg: "Already claimed"
4141
4146
  },
4142
4147
  {
4143
- code: 6013,
4148
+ code: 6014,
4144
4149
  name: "AmountUnderflow",
4145
4150
  msg: "Amount underflow"
4146
4151
  },
4147
4152
  {
4148
- code: 6014,
4153
+ code: 6015,
4149
4154
  name: "InvalidFeeRecipient",
4150
4155
  msg: "Invalid fee recipient"
4151
4156
  },
4152
4157
  {
4153
- code: 6015,
4158
+ code: 6016,
4154
4159
  name: "InvalidStateAccount",
4155
4160
  msg: "Invalid state account"
4156
4161
  },
4157
4162
  {
4158
- code: 6016,
4163
+ code: 6017,
4159
4164
  name: "RecipientIsZero",
4160
4165
  msg: "Recipient cannot be zero"
4161
4166
  },
4162
4167
  {
4163
- code: 6017,
4168
+ code: 6018,
4164
4169
  name: "InvalidCheckType",
4165
4170
  msg: "Invalid checkType"
4166
4171
  },
4167
4172
  {
4168
- code: 6018,
4173
+ code: 6019,
4169
4174
  name: "InvalidCheckParams",
4170
4175
  msg: "CheckParams decode failed"
4171
4176
  },
4172
4177
  {
4173
- code: 6019,
4178
+ code: 6020,
4174
4179
  name: "NoFund",
4175
4180
  msg: "No fund"
4176
4181
  },
4177
4182
  {
4178
- code: 6020,
4183
+ code: 6021,
4179
4184
  name: "NotOwner",
4180
4185
  msg: "Not owner"
4181
4186
  },
4182
4187
  {
4183
- code: 6021,
4188
+ code: 6022,
4184
4189
  name: "NotExpired",
4185
4190
  msg: "Not expired"
4186
4191
  },
4187
4192
  {
4188
- code: 6022,
4193
+ code: 6023,
4189
4194
  name: "UnsupportedTokenType",
4190
4195
  msg: "Unsupported Token Type"
4191
4196
  },
4192
4197
  {
4193
- code: 6023,
4198
+ code: 6024,
4194
4199
  name: "InsufficientSOL",
4195
4200
  msg: "Insufficient SOL"
4196
4201
  },
4197
4202
  {
4198
- code: 6024,
4203
+ code: 6025,
4199
4204
  name: "WrongTokenMint",
4200
4205
  msg: "Wrong token mint"
4201
4206
  },
4202
4207
  {
4203
- code: 6025,
4208
+ code: 6026,
4204
4209
  name: "DeserializationFailed",
4205
4210
  msg: "Deserialization Failed"
4206
4211
  },
4207
4212
  {
4208
- code: 6026,
4213
+ code: 6027,
4209
4214
  name: "JsonParseError",
4210
4215
  msg: "JSON Parse Error"
4211
4216
  },
4212
4217
  {
4213
- code: 6027,
4218
+ code: 6028,
4214
4219
  name: "ResponseLengthError",
4215
4220
  msg: "response length error"
4216
4221
  },
4217
4222
  {
4218
- code: 6028,
4223
+ code: 6029,
4219
4224
  name: "AttUrlError",
4220
4225
  msg: "att url error"
4221
4226
  },
4222
4227
  {
4223
- code: 6029,
4228
+ code: 6030,
4224
4229
  name: "AttSuffixUrlError",
4225
4230
  msg: "att suffix url error"
4226
4231
  },
4227
4232
  {
4228
- code: 6030,
4233
+ code: 6031,
4229
4234
  name: "JsonPathError",
4230
4235
  msg: "json path error"
4231
4236
  },
4232
4237
  {
4233
- code: 6031,
4238
+ code: 6032,
4234
4239
  name: "UsernameKeyError",
4235
4240
  msg: "username key error"
4236
4241
  },
4237
4242
  {
4238
- code: 6032,
4243
+ code: 6033,
4239
4244
  name: "FollowingError",
4240
4245
  msg: "following error"
4241
4246
  },
4242
4247
  {
4243
- code: 6033,
4248
+ code: 6034,
4244
4249
  name: "FollowingNameError",
4245
4250
  msg: "following name error"
4246
4251
  },
4247
4252
  {
4248
- code: 6034,
4253
+ code: 6035,
4249
4254
  name: "NameOpError",
4250
4255
  msg: "name op error"
4251
4256
  },
4252
4257
  {
4253
- code: 6035,
4258
+ code: 6036,
4254
4259
  name: "AttConditionsError",
4255
4260
  msg: "att conditions error"
4256
4261
  },
4257
4262
  {
4258
- code: 6036,
4263
+ code: 6037,
4259
4264
  name: "TooManyUrls",
4260
4265
  msg: "too many urls"
4261
4266
  },
4262
4267
  {
4263
- code: 6037,
4268
+ code: 6038,
4264
4269
  name: "TooManyResponseresolve",
4265
4270
  msg: "too many responseResolve"
4266
4271
  },
4267
4272
  {
4268
- code: 6038,
4273
+ code: 6039,
4269
4274
  name: "UserNameEmpty",
4270
4275
  msg: "user name empty"
4271
4276
  },
4272
4277
  {
4273
- code: 6039,
4278
+ code: 6040,
4274
4279
  name: "SourceError",
4275
4280
  msg: "source error"
4276
4281
  },
4277
4282
  {
4278
- code: 6040,
4283
+ code: 6041,
4279
4284
  name: "AccountResponseLengthError",
4280
4285
  msg: "account response length error"
4281
4286
  },
4282
4287
  {
4283
- code: 6041,
4288
+ code: 6042,
4284
4289
  name: "TiktokAttUrlError",
4285
4290
  msg: "tiktok att url error"
4286
4291
  },
4287
4292
  {
4288
- code: 6042,
4293
+ code: 6043,
4289
4294
  name: "TiktokJsonPathError",
4290
4295
  msg: "tiktok json path error"
4291
4296
  },
4292
4297
  {
4293
- code: 6043,
4298
+ code: 6044,
4294
4299
  name: "XAttUrlError",
4295
4300
  msg: "x att url error"
4296
4301
  },
4297
4302
  {
4298
- code: 6044,
4303
+ code: 6045,
4299
4304
  name: "XJsonPathError",
4300
4305
  msg: "x json path error"
4301
4306
  },
4302
4307
  {
4303
- code: 6045,
4308
+ code: 6046,
4304
4309
  name: "GoogleAttUrlError",
4305
4310
  msg: "google att url error"
4306
4311
  },
4307
4312
  {
4308
- code: 6046,
4313
+ code: 6047,
4309
4314
  name: "GoogleJsonPathError",
4310
4315
  msg: "google json path error"
4311
4316
  },
4312
4317
  {
4313
- code: 6047,
4318
+ code: 6048,
4314
4319
  name: "XiaohongshuAttUrlError",
4315
4320
  msg: "xiaohongshu att url error"
4316
4321
  },
4317
4322
  {
4318
- code: 6048,
4323
+ code: 6049,
4319
4324
  name: "XiaohongshuJsonPathError",
4320
4325
  msg: "xiaohongshu json path error"
4321
4326
  }
@@ -5766,12 +5771,10 @@ async function reSend({
5766
5771
  space,
5767
5772
  programId: redEnvelopeProgram.programId
5768
5773
  });
5769
- debugger;
5770
5774
  const reRecordDataInitIx = await redEnvelopeProgram.methods.reRecordDataInit().accounts({
5771
5775
  reRecordData: spaceAccount.publicKey,
5772
5776
  sender: userKey
5773
5777
  }).signers([spaceAccount]).instruction();
5774
- debugger;
5775
5778
  const [redEnvelopePda] = getPrimusRedEnvelopePda({ programId: redEnvelopeProgram.programId });
5776
5779
  const redEnvelopeState = await redEnvelopeProgram.account.redEnvelopeState.fetch(redEnvelopePda);
5777
5780
  console.log("idCounter", redEnvelopeState.idCounter.toString());
@@ -5796,7 +5799,6 @@ async function reSend({
5796
5799
  toTokenAccount = to.ata;
5797
5800
  tokenProgram = from.tokenProgramId;
5798
5801
  }
5799
- debugger;
5800
5802
  const reSendIx = await redEnvelopeProgram.methods.reSend(Array.from(reId), tipToken, reSendParam).accounts({
5801
5803
  state: redEnvelopePda,
5802
5804
  reRecord: reRecordPda,
@@ -5865,7 +5867,6 @@ async function reClaim({
5865
5867
  console.log(`attBuffer.length=${attBuffer.length}`);
5866
5868
  let storeInitialized = false;
5867
5869
  let useStoreVersion = false;
5868
- debugger;
5869
5870
  if (reRecord.tokenType == ERC20_TYPE && attBuffer.length > ERC20TOKENATTBUFFERMAXLEN || reRecord.tokenType != ERC20_TYPE && attBuffer.length > NATIVETOKENATTBUFFERMAXLEN) {
5870
5871
  useStoreVersion = true;
5871
5872
  }
@@ -5929,6 +5930,7 @@ async function reClaim({
5929
5930
  }).transaction();
5930
5931
  tx.feePayer = userKey;
5931
5932
  tx.recentBlockhash = (await provider.connection.getLatestBlockhash()).blockhash;
5933
+ console.log("UnSigned tx size:", tx.serialize({ requireAllSignatures: false, verifySignatures: false }).length, "bytes");
5932
5934
  const signedTx = await provider.wallet.signTransaction(tx);
5933
5935
  signatureStr = getTxSigStrFromTx(signedTx);
5934
5936
  const isOnChain = await getTxIsOnChain(signatureStr, provider.connection);
@@ -5937,6 +5939,7 @@ async function reClaim({
5937
5939
  return resolve(signatureStr);
5938
5940
  } else {
5939
5941
  const serializeSignedTx = signedTx.serialize();
5942
+ console.log("Signed tx size:", serializeSignedTx.length, "bytes");
5940
5943
  signatureStr = await provider.connection.sendRawTransaction(serializeSignedTx);
5941
5944
  console.log("reClaim done ", signatureStr);
5942
5945
  return resolve(signatureStr);
@@ -6279,7 +6282,6 @@ var ZktlsSdk = class {
6279
6282
  };
6280
6283
 
6281
6284
  // src/index.ts
6282
- console.log("SUPPORTEDCHAINIDS444", SUPPORTEDCHAINIDS);
6283
6285
  var PrimusFund = class {
6284
6286
  supportedChainIds = SUPPORTEDCHAINIDS;
6285
6287
  supportedSocialPlatforms = SUPPORTEDSOCIALPLATFORMS;
@@ -6324,7 +6326,7 @@ var PrimusFund = class {
6324
6326
  } else if (SUPPORTEDSOLANACHAINIDS.includes(chainId)) {
6325
6327
  this.provider = provider;
6326
6328
  this._fundOnSolanaForRedPacket = new FundOnSolanaForRedPacket();
6327
- this._fundOnSolanaForRedPacket.init(provider, chainId);
6329
+ await this._fundOnSolanaForRedPacket.init(provider, chainId);
6328
6330
  }
6329
6331
  if (appId) {
6330
6332
  this._zkTlsSdk = new ZktlsSdk();
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@primuslabs/fund-js-sdk",
3
- "version": "0.1.17",
3
+ "version": "0.1.18",
4
4
  "author": "Primus Labs <dev@primuslabs.org>",
5
5
  "description": "Primus fund js sdk",
6
6
  "repository": {