@streamflow/distributor 8.0.0-alpha.p284.726ba98 → 8.0.0-alpha.p287.84ff30f
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/cjs/index.cjs +19 -4
- package/dist/cjs/index.cjs.map +1 -1
- package/dist/cjs/solana/index.cjs +19 -4
- package/dist/cjs/solana/index.cjs.map +1 -1
- package/dist/esm/index.js +20 -5
- package/dist/esm/index.js.map +1 -1
- package/dist/esm/solana/index.js +20 -5
- package/dist/esm/solana/index.js.map +1 -1
- package/package.json +4 -4
package/dist/cjs/index.cjs
CHANGED
|
@@ -1774,7 +1774,13 @@ var BaseDistributorClient = class {
|
|
|
1774
1774
|
return { distributorPublicKey, ixs };
|
|
1775
1775
|
}
|
|
1776
1776
|
async create(data, extParams) {
|
|
1777
|
-
const
|
|
1777
|
+
const invoker = extParams.invoker.publicKey;
|
|
1778
|
+
common.invariant(invoker, "Invoker's PublicKey is not available, check passed wallet adapter!");
|
|
1779
|
+
const { ixs, distributorPublicKey } = await solana.createAndEstimateTransaction(
|
|
1780
|
+
(params) => this.prepareCreateInstructions(data, { ...params, invoker: extParams.invoker }),
|
|
1781
|
+
extParams,
|
|
1782
|
+
(q) => q.ixs
|
|
1783
|
+
);
|
|
1778
1784
|
const { tx, hash, context } = await solana.prepareTransaction(this.connection, ixs, extParams.invoker.publicKey);
|
|
1779
1785
|
const signature = await wrappedSignAndExecuteTransaction(
|
|
1780
1786
|
this.connection,
|
|
@@ -1794,7 +1800,10 @@ var BaseDistributorClient = class {
|
|
|
1794
1800
|
};
|
|
1795
1801
|
}
|
|
1796
1802
|
async claim(data, extParams) {
|
|
1797
|
-
const ixs = await
|
|
1803
|
+
const ixs = await solana.createAndEstimateTransaction(
|
|
1804
|
+
(params) => this.prepareClaimInstructions(data, { ...params, invoker: extParams.invoker }),
|
|
1805
|
+
extParams
|
|
1806
|
+
);
|
|
1798
1807
|
const { tx, hash, context } = await solana.prepareTransaction(this.connection, ixs, extParams.invoker.publicKey);
|
|
1799
1808
|
const signature = await wrappedSignAndExecuteTransaction(
|
|
1800
1809
|
this.connection,
|
|
@@ -1865,7 +1874,10 @@ var BaseDistributorClient = class {
|
|
|
1865
1874
|
return ixs;
|
|
1866
1875
|
}
|
|
1867
1876
|
async closeClaim(data, extParams) {
|
|
1868
|
-
const ixs = await
|
|
1877
|
+
const ixs = await solana.createAndEstimateTransaction(
|
|
1878
|
+
(params) => this.prepareCloseClaimInstructions(data, { ...params, invoker: extParams.invoker }),
|
|
1879
|
+
extParams
|
|
1880
|
+
);
|
|
1869
1881
|
const { tx, hash, context } = await solana.prepareTransaction(this.connection, ixs, extParams.invoker.publicKey);
|
|
1870
1882
|
const signature = await wrappedSignAndExecuteTransaction(
|
|
1871
1883
|
this.connection,
|
|
@@ -1944,7 +1956,10 @@ var BaseDistributorClient = class {
|
|
|
1944
1956
|
return ixs;
|
|
1945
1957
|
}
|
|
1946
1958
|
async clawback(data, extParams) {
|
|
1947
|
-
const ixs = await
|
|
1959
|
+
const ixs = await solana.createAndEstimateTransaction(
|
|
1960
|
+
(params) => this.prepareClawbackInstructions(data, { ...params, invoker: extParams.invoker }),
|
|
1961
|
+
extParams
|
|
1962
|
+
);
|
|
1948
1963
|
const { tx, hash, context } = await solana.prepareTransaction(this.connection, ixs, extParams.invoker.publicKey);
|
|
1949
1964
|
const signature = await wrappedSignAndExecuteTransaction(
|
|
1950
1965
|
this.connection,
|