@ocap/indexdb 1.18.2 → 1.18.3
Sign up to get free protection for your applications and to get access to all the features.
- package/lib/util.js +10 -0
- package/package.json +4 -4
package/lib/util.js
CHANGED
@@ -134,6 +134,16 @@ const createIndexedTransaction = async (tx, ctx, indexdb) => {
|
|
134
134
|
|
135
135
|
tx.valid = tx.code === 'OK';
|
136
136
|
|
137
|
+
// determine gasPaid
|
138
|
+
let gasChange = null;
|
139
|
+
tx.receipts.forEach((r) => {
|
140
|
+
const tmp = r.changes.find((c) => c.action === 'gas' && c.value === tx.tx.gasFee);
|
141
|
+
if (tmp) {
|
142
|
+
gasChange = tmp;
|
143
|
+
}
|
144
|
+
});
|
145
|
+
tx.tx.gasPaid = gasChange ? tx.tx.gasFee : '0';
|
146
|
+
|
137
147
|
// accounts
|
138
148
|
if (ctx.senderState) {
|
139
149
|
tx.accounts.push(ctx.senderState.address);
|
package/package.json
CHANGED
@@ -3,7 +3,7 @@
|
|
3
3
|
"publishConfig": {
|
4
4
|
"access": "public"
|
5
5
|
},
|
6
|
-
"version": "1.18.
|
6
|
+
"version": "1.18.3",
|
7
7
|
"description": "Defines the basic interface for OCAP IndexDB",
|
8
8
|
"main": "lib/main.js",
|
9
9
|
"files": [
|
@@ -25,10 +25,10 @@
|
|
25
25
|
"jest": "^27.5.1"
|
26
26
|
},
|
27
27
|
"dependencies": {
|
28
|
-
"@ocap/state": "1.18.
|
29
|
-
"@ocap/util": "1.18.
|
28
|
+
"@ocap/state": "1.18.3",
|
29
|
+
"@ocap/util": "1.18.3",
|
30
30
|
"kareem": "^2.4.1",
|
31
31
|
"lodash": "^4.17.21"
|
32
32
|
},
|
33
|
-
"gitHead": "
|
33
|
+
"gitHead": "31b77b9c7247a28dc16f23b2404f08581688ac9e"
|
34
34
|
}
|