File tree Expand file tree Collapse file tree 1 file changed +11
-6
lines changed
src/server/plugins/payment Expand file tree Collapse file tree 1 file changed +11
-6
lines changed Original file line number Diff line number Diff line change @@ -50,9 +50,10 @@ export class PaymentService {
5050 logger . info (
5151 {
5252 event : {
53- category : 'payment' ,
53+ module : 'payment' ,
5454 action : 'create-payment' ,
5555 outcome : 'success' ,
56+ reason : `amount=${ amount } ` ,
5657 reference : response . payment_id
5758 }
5859 } ,
@@ -93,10 +94,13 @@ export class PaymentService {
9394 logger . info (
9495 {
9596 event : {
96- category : 'payment' ,
97+ module : 'payment' ,
9798 action : 'get-payment-status' ,
98- outcome : state . status ,
99- reason : `${ state . code ?? 'N/A' } ${ state . message ?? 'N/A' } ` ,
99+ outcome :
100+ state . status === 'capturable' || state . status === 'success'
101+ ? 'success'
102+ : 'failure' ,
103+ reason : `status:${ state . status } code:${ state . code ?? 'N/A' } message:${ state . message ?? 'N/A' } ` ,
100104 reference : paymentId
101105 }
102106 } ,
@@ -144,9 +148,10 @@ export class PaymentService {
144148 logger . info (
145149 {
146150 event : {
147- category : 'payment' ,
151+ module : 'payment' ,
148152 action : 'capture-payment' ,
149- outcome : `success amount=${ amount } ` ,
153+ outcome : 'success' ,
154+ reason : `amount=${ amount } ` ,
150155 reference : paymentId
151156 }
152157 } ,
You can’t perform that action at this time.
0 commit comments