@polkadot/rpc-core 7.2.2-1 → 7.2.2-10

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/bundle.cjs CHANGED
@@ -255,7 +255,8 @@ class RpcCore {
255
255
  registry: (0, _classPrivateFieldLooseBase2.default)(this, _registryDefault)[_registryDefault]
256
256
  };
257
257
 
258
- const params = this._formatInputs(registry, null, def, values);
258
+ const params = this._formatInputs(registry, null, def, values); // only cache .at(<blockHash>) queries, e.g. where valid blockHash was supplied
259
+
259
260
 
260
261
  const result = await this.provider.send(rpcName, params.map(p => p.toJSON()), !!blockHash);
261
262
  return this._formatResult(isScale, registry, blockHash, method, def, params, result);
package/bundle.js CHANGED
@@ -210,7 +210,8 @@ export class RpcCore {
210
210
  registry: _classPrivateFieldLooseBase(this, _registryDefault)[_registryDefault]
211
211
  };
212
212
 
213
- const params = this._formatInputs(registry, null, def, values);
213
+ const params = this._formatInputs(registry, null, def, values); // only cache .at(<blockHash>) queries, e.g. where valid blockHash was supplied
214
+
214
215
 
215
216
  const result = await this.provider.send(rpcName, params.map(p => p.toJSON()), !!blockHash);
216
217
  return this._formatResult(isScale, registry, blockHash, method, def, params, result);
package/detectOther.cjs CHANGED
@@ -5,9 +5,9 @@ Object.defineProperty(exports, "__esModule", {
5
5
  });
6
6
  exports.default = void 0;
7
7
 
8
- var _packageInfo = require("@polkadot/rpc-provider/packageInfo");
8
+ var _packageInfo = require("@polkadot/rpc-provider/packageInfo.cjs");
9
9
 
10
- var _packageInfo2 = require("@polkadot/types/packageInfo");
10
+ var _packageInfo2 = require("@polkadot/types/packageInfo.cjs");
11
11
 
12
12
  // Copyright 2017-2022 @polkadot/rpc-core authors & contributors
13
13
  // SPDX-License-Identifier: Apache-2.0
package/detectOther.d.ts CHANGED
@@ -1,5 +1,7 @@
1
1
  declare const _default: {
2
2
  name: string;
3
+ path: string;
4
+ type: string;
3
5
  version: string;
4
6
  }[];
5
7
  export default _default;
package/detectOther.js CHANGED
@@ -1,5 +1,5 @@
1
1
  // Copyright 2017-2022 @polkadot/rpc-core authors & contributors
2
2
  // SPDX-License-Identifier: Apache-2.0
3
- import { packageInfo as providerInfo } from '@polkadot/rpc-provider/packageInfo';
4
- import { packageInfo as typesInfo } from '@polkadot/types/packageInfo';
3
+ import { packageInfo as providerInfo } from '@polkadot/rpc-provider/packageInfo.js';
4
+ import { packageInfo as typesInfo } from '@polkadot/types/packageInfo.js';
5
5
  export default [providerInfo, typesInfo];
package/detectPackage.cjs CHANGED
@@ -4,8 +4,6 @@ var _interopRequireDefault = require("@babel/runtime/helpers/interopRequireDefau
4
4
 
5
5
  var _util = require("@polkadot/util");
6
6
 
7
- var _dirname = _interopRequireDefault(require("./cjs/dirname"));
8
-
9
7
  var _detectOther = _interopRequireDefault(require("./detectOther.cjs"));
10
8
 
11
9
  var _packageInfo = require("./packageInfo.cjs");
@@ -13,4 +11,4 @@ var _packageInfo = require("./packageInfo.cjs");
13
11
  // Copyright 2017-2022 @polkadot/rpc-core authors & contributors
14
12
  // SPDX-License-Identifier: Apache-2.0
15
13
  // Do not edit, auto-generated by @polkadot/dev
16
- (0, _util.detectPackage)(_packageInfo.packageInfo, _dirname.default, _detectOther.default);
14
+ (0, _util.detectPackage)(_packageInfo.packageInfo, _packageInfo.packageInfo.path, _detectOther.default);
package/detectPackage.js CHANGED
@@ -2,7 +2,6 @@
2
2
  // SPDX-License-Identifier: Apache-2.0
3
3
  // Do not edit, auto-generated by @polkadot/dev
4
4
  import { detectPackage } from '@polkadot/util';
5
- import dirname from "./cjs/dirname.js";
6
5
  import others from "./detectOther.js";
7
6
  import { packageInfo } from "./packageInfo.js";
8
- detectPackage(packageInfo, dirname, others);
7
+ detectPackage(packageInfo, packageInfo.path, others);
package/package.json CHANGED
@@ -20,20 +20,10 @@
20
20
  "./detectPackage.cjs"
21
21
  ],
22
22
  "type": "module",
23
- "version": "7.2.2-1",
24
- "main": "index.js",
25
- "dependencies": {
26
- "@babel/runtime": "^7.16.7",
27
- "@polkadot/rpc-augment": "7.2.2-1",
28
- "@polkadot/rpc-provider": "7.2.2-1",
29
- "@polkadot/types": "7.2.2-1",
30
- "@polkadot/util": "^8.2.2",
31
- "rxjs": "^7.5.1"
32
- },
33
- "devDependencies": {
34
- "@polkadot/keyring": "^8.2.2",
35
- "@polkadot/rpc-augment": "7.2.2-1"
36
- },
23
+ "version": "7.2.2-10",
24
+ "main": "index.cjs",
25
+ "module": "index.js",
26
+ "types": "index.d.ts",
37
27
  "exports": {
38
28
  ".": {
39
29
  "types": "./index.d.ts",
@@ -45,11 +35,6 @@
45
35
  "require": "./bundle.cjs",
46
36
  "default": "./bundle.js"
47
37
  },
48
- "./cjs/dirname": {
49
- "types": "./cjs/dirname.d.ts",
50
- "default": "./cjs/dirname.js"
51
- },
52
- "./cjs/package.json": "./cjs/package.json",
53
38
  "./detectOther": {
54
39
  "types": "./detectOther.d.ts",
55
40
  "require": "./detectOther.cjs",
@@ -61,6 +46,8 @@
61
46
  "default": "./detectPackage.js"
62
47
  },
63
48
  "./package.json": "./package.json",
49
+ "./packageInfo.cjs": "./packageInfo.cjs",
50
+ "./packageInfo.js": "./packageInfo.js",
64
51
  "./packageInfo": {
65
52
  "types": "./packageInfo.d.ts",
66
53
  "require": "./packageInfo.cjs",
@@ -101,5 +88,13 @@
101
88
  "require": "./util/refCountDelay.cjs",
102
89
  "default": "./util/refCountDelay.js"
103
90
  }
91
+ },
92
+ "dependencies": {
93
+ "@babel/runtime": "^7.16.7",
94
+ "@polkadot/rpc-augment": "7.2.2-10",
95
+ "@polkadot/rpc-provider": "7.2.2-10",
96
+ "@polkadot/types": "7.2.2-10",
97
+ "@polkadot/util": "^8.2.3-30",
98
+ "rxjs": "^7.5.1"
104
99
  }
105
100
  }
package/packageInfo.cjs CHANGED
@@ -9,6 +9,8 @@ exports.packageInfo = void 0;
9
9
  // Do not edit, auto-generated by @polkadot/dev
10
10
  const packageInfo = {
11
11
  name: '@polkadot/rpc-core',
12
- version: '7.2.2-1'
12
+ path: typeof __dirname === 'string' ? __dirname : 'auto',
13
+ type: 'cjs',
14
+ version: '7.2.2-10'
13
15
  };
14
16
  exports.packageInfo = packageInfo;
package/packageInfo.d.ts CHANGED
@@ -1,4 +1,6 @@
1
1
  export declare const packageInfo: {
2
2
  name: string;
3
+ path: string;
4
+ type: string;
3
5
  version: string;
4
6
  };
package/packageInfo.js CHANGED
@@ -3,5 +3,7 @@
3
3
  // Do not edit, auto-generated by @polkadot/dev
4
4
  export const packageInfo = {
5
5
  name: '@polkadot/rpc-core',
6
- version: '7.2.2-1'
6
+ path: new URL('.', import.meta.url).pathname,
7
+ type: 'esm',
8
+ version: '7.2.2-10'
7
9
  };
package/cjs/dirname.d.ts DELETED
@@ -1,8 +0,0 @@
1
- // Copyright 2017-2022 @polkadot/rpc-core authors & contributors
2
- // SPDX-License-Identifier: Apache-2.0
3
-
4
- // Do not edit, auto-generated by @polkadot/dev
5
-
6
- declare const __dirname: string | undefined;
7
-
8
- export default __dirname;
package/cjs/dirname.js DELETED
@@ -1,8 +0,0 @@
1
- // Copyright 2017-2022 @polkadot/rpc-core authors & contributors
2
- // SPDX-License-Identifier: Apache-2.0
3
-
4
- // Do not edit, auto-generated by @polkadot/dev
5
-
6
- module.exports = typeof __dirname === 'string'
7
- ? __dirname.replace('/cjs', '')
8
- : undefined;
package/cjs/package.json DELETED
@@ -1,3 +0,0 @@
1
- {
2
- "type":"commonjs"
3
- }