@snapshot-labs/snapshot.js 0.9.4 → 0.9.6
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/snapshot.cjs.js +2 -5
- package/dist/snapshot.esm.js +2 -5
- package/dist/snapshot.min.js +3 -3
- package/package.json +1 -1
- package/src/delegationSubgraphs.json +1 -1
- package/src/utils.ts +1 -5
package/dist/snapshot.cjs.js
CHANGED
|
@@ -2981,7 +2981,7 @@ var networks = {
|
|
|
2981
2981
|
};
|
|
2982
2982
|
|
|
2983
2983
|
var delegationSubgraphs = {
|
|
2984
|
-
"1": "https://subgrapher.snapshot.org/gateway.thegraph.com/api/0f15b42bdeff7a063a4e1757d7e2f99e/
|
|
2984
|
+
"1": "https://subgrapher.snapshot.org/gateway-arbitrum.network.thegraph.com/api/0f15b42bdeff7a063a4e1757d7e2f99e/subgraphs/id/4YgtogVaqoM8CErHWDK8mKQ825BcVdKB8vBYmb4avAQo",
|
|
2985
2985
|
"5": "https://subgrapher.snapshot.org/api.thegraph.com/subgraphs/name/snapshot-labs/snapshot-goerli",
|
|
2986
2986
|
"10": "https://subgrapher.snapshot.org/api.thegraph.com/subgraphs/name/snapshot-labs/snapshot-optimism",
|
|
2987
2987
|
"56": "https://subgrapher.snapshot.org/api.thegraph.com/subgraphs/name/snapshot-labs/snapshot-binance-smart-chain",
|
|
@@ -3447,7 +3447,6 @@ ajv.addFormat('ethValue', {
|
|
|
3447
3447
|
});
|
|
3448
3448
|
var networksIds = Object.keys(networks);
|
|
3449
3449
|
var mainnetNetworkIds = Object.keys(networks).filter(function (id) { return !networks[id].testnet; });
|
|
3450
|
-
var testnetNetworkIds = Object.keys(networks).filter(function (id) { return networks[id].testnet; });
|
|
3451
3450
|
ajv.addKeyword({
|
|
3452
3451
|
keyword: 'snapshotNetwork',
|
|
3453
3452
|
validate: function (schema, data) {
|
|
@@ -3455,12 +3454,10 @@ ajv.addKeyword({
|
|
|
3455
3454
|
var snapshotEnv = this.snapshotEnv || 'default';
|
|
3456
3455
|
if (snapshotEnv === 'mainnet')
|
|
3457
3456
|
return mainnetNetworkIds.includes(data);
|
|
3458
|
-
if (snapshotEnv === 'testnet')
|
|
3459
|
-
return testnetNetworkIds.includes(data);
|
|
3460
3457
|
return networksIds.includes(data);
|
|
3461
3458
|
},
|
|
3462
3459
|
error: {
|
|
3463
|
-
message: '
|
|
3460
|
+
message: 'network not allowed'
|
|
3464
3461
|
}
|
|
3465
3462
|
});
|
|
3466
3463
|
// Custom URL format to allow empty string values
|
package/dist/snapshot.esm.js
CHANGED
|
@@ -2972,7 +2972,7 @@ var networks = {
|
|
|
2972
2972
|
};
|
|
2973
2973
|
|
|
2974
2974
|
var delegationSubgraphs = {
|
|
2975
|
-
"1": "https://subgrapher.snapshot.org/gateway.thegraph.com/api/0f15b42bdeff7a063a4e1757d7e2f99e/
|
|
2975
|
+
"1": "https://subgrapher.snapshot.org/gateway-arbitrum.network.thegraph.com/api/0f15b42bdeff7a063a4e1757d7e2f99e/subgraphs/id/4YgtogVaqoM8CErHWDK8mKQ825BcVdKB8vBYmb4avAQo",
|
|
2976
2976
|
"5": "https://subgrapher.snapshot.org/api.thegraph.com/subgraphs/name/snapshot-labs/snapshot-goerli",
|
|
2977
2977
|
"10": "https://subgrapher.snapshot.org/api.thegraph.com/subgraphs/name/snapshot-labs/snapshot-optimism",
|
|
2978
2978
|
"56": "https://subgrapher.snapshot.org/api.thegraph.com/subgraphs/name/snapshot-labs/snapshot-binance-smart-chain",
|
|
@@ -3438,7 +3438,6 @@ ajv.addFormat('ethValue', {
|
|
|
3438
3438
|
});
|
|
3439
3439
|
var networksIds = Object.keys(networks);
|
|
3440
3440
|
var mainnetNetworkIds = Object.keys(networks).filter(function (id) { return !networks[id].testnet; });
|
|
3441
|
-
var testnetNetworkIds = Object.keys(networks).filter(function (id) { return networks[id].testnet; });
|
|
3442
3441
|
ajv.addKeyword({
|
|
3443
3442
|
keyword: 'snapshotNetwork',
|
|
3444
3443
|
validate: function (schema, data) {
|
|
@@ -3446,12 +3445,10 @@ ajv.addKeyword({
|
|
|
3446
3445
|
var snapshotEnv = this.snapshotEnv || 'default';
|
|
3447
3446
|
if (snapshotEnv === 'mainnet')
|
|
3448
3447
|
return mainnetNetworkIds.includes(data);
|
|
3449
|
-
if (snapshotEnv === 'testnet')
|
|
3450
|
-
return testnetNetworkIds.includes(data);
|
|
3451
3448
|
return networksIds.includes(data);
|
|
3452
3449
|
},
|
|
3453
3450
|
error: {
|
|
3454
|
-
message: '
|
|
3451
|
+
message: 'network not allowed'
|
|
3455
3452
|
}
|
|
3456
3453
|
});
|
|
3457
3454
|
// Custom URL format to allow empty string values
|