diff --git a/backend/controllers/eclair/channels.js b/backend/controllers/eclair/channels.js index 69b544d4..bb840a07 100644 --- a/backend/controllers/eclair/channels.js +++ b/backend/controllers/eclair/channels.js @@ -194,19 +194,19 @@ export const circularRebalance = (req, res, next) => { return res.status(201).json({ flgReusingInvoice: !!foundExistingInvoice, invoice: invoice, paymentHash: paymentHash, paymentDetails: payToRouteCallRes, paymentStatus: payStatus }); }).catch((errRes) => { const err = common.handleError(errRes, 'Channels', 'Channel Rebalance From Sent Info Error', req.session.selectedNode); - return res.status(err.statusCode).json({ flgReusingInvoice: !!foundExistingInvoice, invoice: invoice, paymentHash: paymentHash, paymentDetails: payToRouteCallRes, paymentStatus: { message: err.message, error: err.error } }); + return res.status(err.statusCode).json({ flgReusingInvoice: !!foundExistingInvoice, invoice: invoice, paymentHash: paymentHash, paymentDetails: payToRouteCallRes, paymentStatus: err.error }); }); }, 3000); }).catch((errRes) => { const err = common.handleError(errRes, 'Channels', 'Channel Rebalance From Send Payment To Route Error', req.session.selectedNode); - return res.status(err.statusCode).json({ flgReusingInvoice: !!foundExistingInvoice, invoice: invoice, paymentHash: paymentHash, paymentDetails: {}, paymentStatus: { message: err.message, error: err.error } }); + return res.status(err.statusCode).json({ flgReusingInvoice: !!foundExistingInvoice, invoice: invoice, paymentHash: paymentHash, paymentDetails: {}, paymentStatus: err.error }); }); }).catch((errRes) => { const err = common.handleError(errRes, 'Channels', 'Channel Rebalance From Find Routes Error', req.session.selectedNode); - return res.status(err.statusCode).json({ flgReusingInvoice: !!foundExistingInvoice, invoice: (foundExistingInvoice.serialized || ''), paymentHash: '', paymentDetails: {}, paymentStatus: { message: err.message, error: err.error } }); + return res.status(err.statusCode).json({ flgReusingInvoice: !!foundExistingInvoice, invoice: (foundExistingInvoice.serialized || ''), paymentHash: '', paymentDetails: {}, paymentStatus: err.error }); }); }).catch((errRes) => { const err = common.handleError(errRes, 'Channels', 'Channel Rebalance From List Pending Invoices Error', req.session.selectedNode); - return res.status(err.statusCode).json({ flgReusingInvoice: false, invoice: '', paymentHash: '', paymentDetails: {}, paymentStatus: { message: err.message, error: err.error } }); + return res.status(err.statusCode).json({ flgReusingInvoice: false, invoice: '', paymentHash: '', paymentDetails: {}, paymentStatus: err.error }); }); }; diff --git a/server/controllers/eclair/channels.ts b/server/controllers/eclair/channels.ts index a280e31a..8368b34f 100644 --- a/server/controllers/eclair/channels.ts +++ b/server/controllers/eclair/channels.ts @@ -189,20 +189,20 @@ export const circularRebalance = (req, res, next) => { return res.status(201).json({ flgReusingInvoice: !!foundExistingInvoice, invoice: invoice, paymentHash: paymentHash, paymentDetails: payToRouteCallRes, paymentStatus: payStatus }); }).catch((errRes) => { const err = common.handleError(errRes, 'Channels', 'Channel Rebalance From Sent Info Error', req.session.selectedNode); - return res.status(err.statusCode).json({ flgReusingInvoice: !!foundExistingInvoice, invoice: invoice, paymentHash: paymentHash, paymentDetails: payToRouteCallRes, paymentStatus: { message: err.message, error: err.error } }); + return res.status(err.statusCode).json({ flgReusingInvoice: !!foundExistingInvoice, invoice: invoice, paymentHash: paymentHash, paymentDetails: payToRouteCallRes, paymentStatus: err.error }); }); }, 3000); }).catch((errRes) => { const err = common.handleError(errRes, 'Channels', 'Channel Rebalance From Send Payment To Route Error', req.session.selectedNode); - return res.status(err.statusCode).json({ flgReusingInvoice: !!foundExistingInvoice, invoice: invoice, paymentHash: paymentHash, paymentDetails: {}, paymentStatus: { message: err.message, error: err.error } }); + return res.status(err.statusCode).json({ flgReusingInvoice: !!foundExistingInvoice, invoice: invoice, paymentHash: paymentHash, paymentDetails: {}, paymentStatus: err.error }); }); }).catch((errRes) => { const err = common.handleError(errRes, 'Channels', 'Channel Rebalance From Find Routes Error', req.session.selectedNode); - return res.status(err.statusCode).json({ flgReusingInvoice: !!foundExistingInvoice, invoice: (foundExistingInvoice.serialized || ''), paymentHash: '', paymentDetails: {}, paymentStatus: { message: err.message, error: err.error } }); + return res.status(err.statusCode).json({ flgReusingInvoice: !!foundExistingInvoice, invoice: (foundExistingInvoice.serialized || ''), paymentHash: '', paymentDetails: {}, paymentStatus: err.error }); }); }).catch((errRes) => { const err = common.handleError(errRes, 'Channels', 'Channel Rebalance From List Pending Invoices Error', req.session.selectedNode); - return res.status(err.statusCode).json({ flgReusingInvoice: false, invoice: '', paymentHash: '', paymentDetails: {}, paymentStatus: { message: err.message, error: err.error } }); + return res.status(err.statusCode).json({ flgReusingInvoice: false, invoice: '', paymentHash: '', paymentDetails: {}, paymentStatus: err.error }); }); }; diff --git a/src/app/eclair/peers-channels/channels/channel-rebalance-modal/channel-rebalance.component.html b/src/app/eclair/peers-channels/channels/channel-rebalance-modal/channel-rebalance.component.html index 3592ed0e..c4d81cf9 100644 --- a/src/app/eclair/peers-channels/channels/channel-rebalance-modal/channel-rebalance.component.html +++ b/src/app/eclair/peers-channels/channels/channel-rebalance-modal/channel-rebalance.component.html @@ -64,11 +64,11 @@
{{rebalanceStatus.invoice}}
- + - {{!rebalanceStatus.paymentStatus?.route ? 'Searching route...' : rebalanceStatus.paymentStatus?.type === 'pending' ? 'Route info pending...' : 'Route used'}}{{rebalanceStatus.paymentStatus?.route ? 'check' : 'close'}} + {{rebalanceStatus.paymentStatus?.error ? 'Route search failed' : !rebalanceStatus.paymentStatus?.route ? 'Searching route...' : rebalanceStatus.paymentStatus?.type === 'pending' ? 'Route info pending...' : 'Route used'}}{{rebalanceStatus.paymentStatus?.route ? 'check' : 'close'}}
diff --git a/src/app/lnd/graph/lookups/node-lookup/node-lookup.component.html b/src/app/lnd/graph/lookups/node-lookup/node-lookup.component.html index 665177e2..c1643e1d 100644 --- a/src/app/lnd/graph/lookups/node-lookup/node-lookup.component.html +++ b/src/app/lnd/graph/lookups/node-lookup/node-lookup.component.html @@ -54,7 +54,7 @@ Connect - Copy URI + Copy URI
diff --git a/src/app/lnd/graph/lookups/node-lookup/node-lookup.component.ts b/src/app/lnd/graph/lookups/node-lookup/node-lookup.component.ts index ee49f74a..07b91445 100644 --- a/src/app/lnd/graph/lookups/node-lookup/node-lookup.component.ts +++ b/src/app/lnd/graph/lookups/node-lookup/node-lookup.component.ts @@ -46,7 +46,7 @@ export class NodeLookupComponent implements OnInit, OnDestroy { this.store.dispatch(openAlert({ payload: { data: { - message: { peer: { pub_key: this.lookupResult.node?.pub_key, address: address }, information: this.information, balance: this.availableBalance }, + message: { peer: { pub_key: this.lookupResult.node?.pub_key, address: address.addr }, information: this.information, balance: this.availableBalance }, component: ConnectPeerComponent } } diff --git a/src/app/shared/services/data.service.ts b/src/app/shared/services/data.service.ts index cec7e86c..97b431fc 100644 --- a/src/app/shared/services/data.service.ts +++ b/src/app/shared/services/data.service.ts @@ -340,7 +340,7 @@ export class DataService implements OnDestroy { map((res: any) => res), catchError((err) => { this.handleErrorWithoutAlert('Rebalance Channel', UI_MESSAGES.REBALANCE_CHANNEL, err); - return throwError(() => new Error(this.extractErrorMessage(err))); + return throwError(() => err.error); }) ); } diff --git a/src/app/shared/theme/styles/theme-mode-dark.scss b/src/app/shared/theme/styles/theme-mode-dark.scss index 1265b59e..546f7bec 100644 --- a/src/app/shared/theme/styles/theme-mode-dark.scss +++ b/src/app/shared/theme/styles/theme-mode-dark.scss @@ -43,7 +43,7 @@ color: $foreground-text; } .mat-mdc-button-base.mat-mdc-unelevated-button.mat-primary { - color: $foreground-text; + color: $foreground-text !important; } .mat-mdc-option:hover:not(.mdc-list-item--disabled), .mat-mdc-option.mdc-list-item--selected:not(.mat-mdc-option-multiple):not(.mdc-list-item--disabled) { & .mdc-list-item__primary-text {