Skip to content

Commit 7e639e0

Browse files
committed
fixed issue with sign-a-transaction default nativeData being undefined now is object
1 parent f59b702 commit 7e639e0

File tree

1 file changed

+8
-10
lines changed

1 file changed

+8
-10
lines changed

components/overledger/actions/sign-a-transaction/sign-a-transaction.mjs

Lines changed: 8 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -15,6 +15,13 @@ export default {
1515
"environment",
1616
],
1717
},
18+
locationTechnology: {
19+
type: "string",
20+
label: "Location Technology",
21+
description: "The blockchain technology used for this transaction, e.g., ethereum, substrate - required in order to set the dltfee",
22+
//previous prep step output - reuired in this step in order to set the dltfee unit
23+
default: ({ steps }) => steps.prepare_smart_contract_transaction?.locationTechnology || "ethereum",
24+
},
1825
keyId: {
1926
type: "string",
2027
label: "Signing Account ID",
@@ -34,19 +41,10 @@ export default {
3441
type: "object",
3542
label: "Native Data",
3643
description: "A JSON object representing the transaction required to be signed.",
37-
optional: true,
3844
// Reference the output of the previous step
39-
default: ({ steps }) => steps.prepare_smart_contract_transaction?.nativeData,
45+
default: ({ steps }) => steps.prepare_smart_contract_transaction?.nativeData || {},
4046
},
4147
},
42-
locationTechnology: {
43-
type: "string",
44-
label: "Location Technology",
45-
description: "The blockchain technology used for this transaction, e.g., ethereum, substrate.",
46-
optional: true,
47-
// Reference the output of the previous step
48-
default: ({ steps }) => steps.prepare_smart_contract_transaction?.locationTechnology,
49-
},
5048
async run({ $ }) {
5149
//default values of gatewayFee and dltfee hard coded into params.
5250
const gatewayFee = {

0 commit comments

Comments
 (0)