From 7363309801ea82358a94b745a416826fc3a3c197 Mon Sep 17 00:00:00 2001 From: ShahanaFarooqui Date: Thu, 27 Oct 2022 16:19:20 -0700 Subject: [PATCH] Bug fix: Table null data error --- src/app/cln/graph/lookups/lookups.component.ts | 1 - .../cln/graph/lookups/node-lookup/node-lookup.component.ts | 2 +- src/app/cln/graph/query-routes/query-routes.component.ts | 3 +-- .../liquidity-ads-list/liquidity-ads-list.component.ts | 2 +- src/app/cln/on-chain/utxo-tables/utxos/utxos.component.ts | 2 +- .../channel-open-table/channel-open-table.component.ts | 2 +- .../channel-pending-table/channel-pending-table.component.ts | 2 +- src/app/cln/peers-channels/peers/peers.component.ts | 2 +- .../failed-transactions/failed-transactions.component.ts | 4 ++-- .../forwarding-history/forwarding-history.component.ts | 2 +- .../local-failed-transactions.component.ts | 4 ++-- .../invoices/create-invoice-modal/create-invoice.component.ts | 1 - .../invoices-table/lightning-invoices-table.component.ts | 2 +- .../offers/create-offer-modal/create-offer.component.ts | 1 - .../offer-bookmarks-table/offer-bookmarks-table.component.ts | 2 +- .../cln/transactions/payments/lightning-payments.component.ts | 2 +- src/app/eclair/graph/lookups/lookups.component.ts | 1 - .../eclair/graph/lookups/node-lookup/node-lookup.component.ts | 2 +- .../on-chain-transaction-history.component.ts | 2 +- .../channel-inactive-table.component.ts | 2 +- .../channel-open-table/channel-open-table.component.ts | 2 +- .../channel-pending-table/channel-pending-table.component.ts | 2 +- src/app/eclair/peers-channels/peers/peers.component.ts | 2 +- .../forwarding-history/forwarding-history.component.ts | 2 +- .../eclair/routing/routing-peers/routing-peers.component.ts | 4 ++-- .../create-invoice-modal/create-invoice.component.ts | 1 - .../transactions/invoices/lightning-invoices.component.ts | 2 +- .../channel-backup-table/channel-backup-table.component.ts | 2 +- .../channel-restore-table/channel-restore-table.component.ts | 2 +- src/app/lnd/graph/lookups/lookups.component.ts | 1 - src/app/lnd/graph/query-routes/query-routes.component.ts | 2 +- .../on-chain-transaction-history.component.ts | 2 +- src/app/lnd/on-chain/utxo-tables/utxos/utxos.component.ts | 2 +- .../channel-active-htlcs-table.component.ts | 2 +- .../channel-closed-table/channel-closed-table.component.ts | 2 +- .../channel-open-table/channel-open-table.component.ts | 2 +- src/app/lnd/peers-channels/peers/peers.component.ts | 2 +- .../forwarding-history/forwarding-history.component.ts | 2 +- .../create-invoice-modal/create-invoice.component.ts | 1 - .../lookup-transactions/lookup-transactions.component.ts | 1 - .../lnd/transactions/payments/lightning-payments.component.ts | 2 +- .../components/ln-services/boltz/swaps/swaps.component.ts | 2 +- .../components/ln-services/loop/swaps/swaps.component.ts | 2 +- .../transactions-report-table.component.ts | 2 +- 44 files changed, 39 insertions(+), 48 deletions(-) diff --git a/src/app/cln/graph/lookups/lookups.component.ts b/src/app/cln/graph/lookups/lookups.component.ts index 1f4fba95..d9a0a680 100644 --- a/src/app/cln/graph/lookups/lookups.component.ts +++ b/src/app/cln/graph/lookups/lookups.component.ts @@ -24,7 +24,6 @@ export class CLNLookupsComponent implements OnInit, OnDestroy { public nodeLookupValue = { nodeid: '' }; public channelLookupValue = []; public flgSetLookupValue = false; - public temp: any; public messageObj = []; public selectedFieldId = 0; public lookupFields = [ diff --git a/src/app/cln/graph/lookups/node-lookup/node-lookup.component.ts b/src/app/cln/graph/lookups/node-lookup/node-lookup.component.ts index 6fc46973..b0810a90 100644 --- a/src/app/cln/graph/lookups/node-lookup/node-lookup.component.ts +++ b/src/app/cln/graph/lookups/node-lookup/node-lookup.component.ts @@ -17,7 +17,7 @@ export class CLNNodeLookupComponent implements OnInit { @ViewChild(MatSort, { static: false }) sort: MatSort | undefined; @Input() lookupResult: LookupNode; public featureDescriptions: string[] = []; - public addresses: any; + public addresses: any = new MatTableDataSource([]); public displayedColumns = ['type', 'address', 'port', 'actions']; constructor(private logger: LoggerService, private snackBar: MatSnackBar) { } diff --git a/src/app/cln/graph/query-routes/query-routes.component.ts b/src/app/cln/graph/query-routes/query-routes.component.ts index 2329bde2..7943cd75 100644 --- a/src/app/cln/graph/query-routes/query-routes.component.ts +++ b/src/app/cln/graph/query-routes/query-routes.component.ts @@ -31,7 +31,7 @@ export class CLNQueryRoutesComponent implements OnInit, OnDestroy { public tableSetting: TableSetting = { tableId: 'query_routes', recordsPerPage: PAGE_SIZE, sortBy: 'id', sortOrder: SortOrderEnum.ASCENDING }; public destinationPubkey = ''; public amount: number | null = null; - public qrHops: any; + public qrHops: any = new MatTableDataSource([]); public displayedColumns: any[] = []; public flgLoading: Array = [false]; // 0: peers public faRoute = faRoute; @@ -56,7 +56,6 @@ export class CLNQueryRoutesComponent implements OnInit, OnDestroy { this.displayedColumns.push('actions'); }); this.clnEffects.setQueryRoutesCL.pipe(takeUntil(this.unSubs[1])).subscribe((queryRoute) => { - this.qrHops = new MatTableDataSource([]); this.qrHops.data = []; if (queryRoute.routes && queryRoute.routes.length && queryRoute.routes.length > 0) { this.flgLoading[0] = false; diff --git a/src/app/cln/liquidity-ads/liquidity-ads-list/liquidity-ads-list.component.ts b/src/app/cln/liquidity-ads/liquidity-ads-list/liquidity-ads-list.component.ts index d6fbb5f8..ef0411fd 100644 --- a/src/app/cln/liquidity-ads/liquidity-ads-list/liquidity-ads-list.component.ts +++ b/src/app/cln/liquidity-ads/liquidity-ads-list/liquidity-ads-list.component.ts @@ -49,7 +49,7 @@ export class CLNLiquidityAdsListComponent implements OnInit, OnDestroy { public node_capacity = 500000; public channel_count = 5; public liquidityNodesData: LookupNode[] = []; - public liquidityNodes: any; + public liquidityNodes: any = new MatTableDataSource([]); public pageSize = PAGE_SIZE; public pageSizeOptions = PAGE_SIZE_OPTIONS; public screenSize = ''; diff --git a/src/app/cln/on-chain/utxo-tables/utxos/utxos.component.ts b/src/app/cln/on-chain/utxo-tables/utxos/utxos.component.ts index fccc241b..492de2a5 100644 --- a/src/app/cln/on-chain/utxo-tables/utxos/utxos.component.ts +++ b/src/app/cln/on-chain/utxo-tables/utxos/utxos.component.ts @@ -36,7 +36,7 @@ export class CLNOnChainUtxosComponent implements OnInit, AfterViewInit, OnDestro public tableSetting: TableSetting = { tableId: 'utxos', recordsPerPage: PAGE_SIZE, sortBy: 'status', sortOrder: SortOrderEnum.DESCENDING }; public displayedColumns: any[] = []; public utxos: UTXO[]; - public listUTXOs: any; + public listUTXOs: any = new MatTableDataSource([]); public pageSize = PAGE_SIZE; public pageSizeOptions = PAGE_SIZE_OPTIONS; public screenSize = ''; diff --git a/src/app/cln/peers-channels/channels/channels-tables/channel-open-table/channel-open-table.component.ts b/src/app/cln/peers-channels/channels/channels-tables/channel-open-table/channel-open-table.component.ts index 8f844986..438699fd 100644 --- a/src/app/cln/peers-channels/channels/channels-tables/channel-open-table/channel-open-table.component.ts +++ b/src/app/cln/peers-channels/channels/channels-tables/channel-open-table/channel-open-table.component.ts @@ -43,7 +43,7 @@ export class CLNChannelOpenTableComponent implements OnInit, AfterViewInit, OnDe public totalBalance = 0; public displayedColumns: any[] = []; public channelsData: Channel[] = []; - public channels: any; + public channels: any = new MatTableDataSource([]); public myChanPolicy: any = {}; public information: GetInfo = {}; public numPeers = -1; diff --git a/src/app/cln/peers-channels/channels/channels-tables/channel-pending-table/channel-pending-table.component.ts b/src/app/cln/peers-channels/channels/channels-tables/channel-pending-table/channel-pending-table.component.ts index 1f9b82a8..ba752cc1 100644 --- a/src/app/cln/peers-channels/channels/channels-tables/channel-pending-table/channel-pending-table.component.ts +++ b/src/app/cln/peers-channels/channels/channels-tables/channel-pending-table/channel-pending-table.component.ts @@ -42,7 +42,7 @@ export class CLNChannelPendingTableComponent implements OnInit, AfterViewInit, O public totalBalance = 0; public displayedColumns: any[] = []; public channelsData: Channel[] = []; - public channels: any; + public channels: any = new MatTableDataSource([]); public myChanPolicy: any = {}; public information: GetInfo = {}; public numPeers = -1; diff --git a/src/app/cln/peers-channels/peers/peers.component.ts b/src/app/cln/peers-channels/peers/peers.component.ts index b33e3155..37fdf2cf 100644 --- a/src/app/cln/peers-channels/peers/peers.component.ts +++ b/src/app/cln/peers-channels/peers/peers.component.ts @@ -43,7 +43,7 @@ export class CLNPeersComponent implements OnInit, AfterViewInit, OnDestroy { public displayedColumns: any[] = []; public peerAddress: string | null = ''; public peersData: Peer[] = []; - public peers: any; + public peers: any = new MatTableDataSource([]); public information: GetInfo = {}; public availableBalance = 0; public pageSize = PAGE_SIZE; diff --git a/src/app/cln/routing/failed-transactions/failed-transactions.component.ts b/src/app/cln/routing/failed-transactions/failed-transactions.component.ts index 4af76c2c..1c03c93f 100644 --- a/src/app/cln/routing/failed-transactions/failed-transactions.component.ts +++ b/src/app/cln/routing/failed-transactions/failed-transactions.component.ts @@ -36,10 +36,10 @@ export class CLNFailedTransactionsComponent implements OnInit, AfterViewInit, On public PAGE_ID = 'routing'; public tableSetting: TableSetting = { tableId: 'failed', recordsPerPage: PAGE_SIZE, sortBy: 'received_time', sortOrder: SortOrderEnum.DESCENDING }; public faExclamationTriangle = faExclamationTriangle; - public failedEvents: any; + public failedEvents: any[] = []; public errorMessage = ''; public displayedColumns: any[] = []; - public failedForwardingEvents: any; + public failedForwardingEvents: any = new MatTableDataSource([]); public selFilter = ''; public totalFailedTransactions = 0; public pageSize = PAGE_SIZE; diff --git a/src/app/cln/routing/forwarding-history/forwarding-history.component.ts b/src/app/cln/routing/forwarding-history/forwarding-history.component.ts index 0d30e23c..6a25a8a9 100644 --- a/src/app/cln/routing/forwarding-history/forwarding-history.component.ts +++ b/src/app/cln/routing/forwarding-history/forwarding-history.component.ts @@ -39,7 +39,7 @@ export class CLNForwardingHistoryComponent implements OnInit, OnChanges, AfterVi public tableSetting: TableSetting = { tableId: 'forwarding_history', recordsPerPage: PAGE_SIZE, sortBy: 'received_time', sortOrder: SortOrderEnum.DESCENDING }; public successfulEvents: ForwardingEvent[] = []; public displayedColumns: any[] = []; - public forwardingHistoryEvents: any; + public forwardingHistoryEvents: any = new MatTableDataSource([]); public totalForwardedTransactions = 0; public pageSize = PAGE_SIZE; public pageSizeOptions = PAGE_SIZE_OPTIONS; diff --git a/src/app/cln/routing/local-failed-transactions/local-failed-transactions.component.ts b/src/app/cln/routing/local-failed-transactions/local-failed-transactions.component.ts index 4b0e1d8d..c5d4d185 100644 --- a/src/app/cln/routing/local-failed-transactions/local-failed-transactions.component.ts +++ b/src/app/cln/routing/local-failed-transactions/local-failed-transactions.component.ts @@ -37,10 +37,10 @@ export class CLNLocalFailedTransactionsComponent implements OnInit, AfterViewIni public PAGE_ID = 'routing'; public tableSetting: TableSetting = { tableId: 'local_failed', recordsPerPage: PAGE_SIZE, sortBy: 'received_time', sortOrder: SortOrderEnum.DESCENDING }; public CLNFailReason = CLNFailReason; - public failedLocalEvents: any; + public failedLocalEvents: any[] = []; public errorMessage = ''; public displayedColumns: any[] = []; - public failedLocalForwardingEvents: any; + public failedLocalForwardingEvents: any = new MatTableDataSource([]); public selFilter = ''; public totalLocalFailedTransactions = 0; public pageSize = PAGE_SIZE; diff --git a/src/app/cln/transactions/invoices/create-invoice-modal/create-invoice.component.ts b/src/app/cln/transactions/invoices/create-invoice-modal/create-invoice.component.ts index 49a896f2..a449fcba 100644 --- a/src/app/cln/transactions/invoices/create-invoice-modal/create-invoice.component.ts +++ b/src/app/cln/transactions/invoices/create-invoice-modal/create-invoice.component.ts @@ -31,7 +31,6 @@ export class CLNCreateInvoiceComponent implements OnInit, OnDestroy { public invoiceValue: number | null; public invoiceValueHint = ''; public invoicePaymentReq = ''; - public invoices: any; public information: GetInfo = {}; public private = false; public expiryStep = 100; diff --git a/src/app/cln/transactions/invoices/invoices-table/lightning-invoices-table.component.ts b/src/app/cln/transactions/invoices/invoices-table/lightning-invoices-table.component.ts index 7a440d60..4fc50913 100644 --- a/src/app/cln/transactions/invoices/invoices-table/lightning-invoices-table.component.ts +++ b/src/app/cln/transactions/invoices/invoices-table/lightning-invoices-table.component.ts @@ -51,7 +51,7 @@ export class CLNLightningInvoicesTableComponent implements OnInit, AfterViewInit public invoiceValueHint = ''; public displayedColumns: any[] = []; public invoicePaymentReq = ''; - public invoices: any; + public invoices: any = new MatTableDataSource([]); public invoiceJSONArr: Invoice[] = []; public information: GetInfo = {}; public private = false; diff --git a/src/app/cln/transactions/offers/create-offer-modal/create-offer.component.ts b/src/app/cln/transactions/offers/create-offer-modal/create-offer.component.ts index dc6e0807..dc275493 100644 --- a/src/app/cln/transactions/offers/create-offer-modal/create-offer.component.ts +++ b/src/app/cln/transactions/offers/create-offer-modal/create-offer.component.ts @@ -30,7 +30,6 @@ export class CLNCreateOfferComponent implements OnInit, OnDestroy { public offerValue: number | null; public vendor = ''; public offerValueHint = ''; - public offers: any; public information: GetInfo = {}; public pageSize = PAGE_SIZE; public offerError = ''; diff --git a/src/app/cln/transactions/offers/offer-bookmarks-table/offer-bookmarks-table.component.ts b/src/app/cln/transactions/offers/offer-bookmarks-table/offer-bookmarks-table.component.ts index 765a45f1..556fd5dd 100644 --- a/src/app/cln/transactions/offers/offer-bookmarks-table/offer-bookmarks-table.component.ts +++ b/src/app/cln/transactions/offers/offer-bookmarks-table/offer-bookmarks-table.component.ts @@ -38,7 +38,7 @@ export class CLNOfferBookmarksTableComponent implements OnInit, AfterViewInit, O public PAGE_ID = 'transactions'; public tableSetting: TableSetting = { tableId: 'offer_bookmarks', recordsPerPage: PAGE_SIZE, sortBy: 'lastUpdatedAt', sortOrder: SortOrderEnum.DESCENDING }; public displayedColumns: any[] = []; - public offersBookmarks: any; + public offersBookmarks: any = new MatTableDataSource([]); public offersBookmarksJSONArr: OfferBookmark[] = []; public pageSize = PAGE_SIZE; public pageSizeOptions = PAGE_SIZE_OPTIONS; diff --git a/src/app/cln/transactions/payments/lightning-payments.component.ts b/src/app/cln/transactions/payments/lightning-payments.component.ts index 2bf5ac0e..8afa2068 100644 --- a/src/app/cln/transactions/payments/lightning-payments.component.ts +++ b/src/app/cln/transactions/payments/lightning-payments.component.ts @@ -46,7 +46,7 @@ export class CLNLightningPaymentsComponent implements OnInit, AfterViewInit, OnD public newlyAddedPayment = ''; public selNode: SelNodeChild | null = {}; public information: GetInfo = {}; - public payments: any; + public payments: any = new MatTableDataSource([]); public paymentJSONArr: Payment[] = []; public displayedColumns: any[] = []; public mppColumns: string[] = []; diff --git a/src/app/eclair/graph/lookups/lookups.component.ts b/src/app/eclair/graph/lookups/lookups.component.ts index 6fd04dee..2fd8191a 100644 --- a/src/app/eclair/graph/lookups/lookups.component.ts +++ b/src/app/eclair/graph/lookups/lookups.component.ts @@ -27,7 +27,6 @@ export class ECLLookupsComponent implements OnInit, OnDestroy { public nodeLookupValue: LookupNode = {}; public channelLookupValue = []; public flgSetLookupValue = false; - public temp: any; public messageObj = []; public selectedFieldId = 0; public lookupFields = [ diff --git a/src/app/eclair/graph/lookups/node-lookup/node-lookup.component.ts b/src/app/eclair/graph/lookups/node-lookup/node-lookup.component.ts index 1dcc6816..e3473524 100644 --- a/src/app/eclair/graph/lookups/node-lookup/node-lookup.component.ts +++ b/src/app/eclair/graph/lookups/node-lookup/node-lookup.component.ts @@ -16,7 +16,7 @@ export class ECLNodeLookupComponent implements OnInit { @ViewChild(MatSort, { static: false }) sort: MatSort | undefined; @Input() lookupResult: LookupNode = {}; - public addresses: any; + public addresses: any = new MatTableDataSource([]); public displayedColumns = ['address', 'actions']; public nodeFeaturesEnum = NodeFeaturesECL; diff --git a/src/app/eclair/on-chain/on-chain-transaction-history/on-chain-transaction-history.component.ts b/src/app/eclair/on-chain/on-chain-transaction-history/on-chain-transaction-history.component.ts index ffba0287..9101759d 100644 --- a/src/app/eclair/on-chain/on-chain-transaction-history/on-chain-transaction-history.component.ts +++ b/src/app/eclair/on-chain/on-chain-transaction-history/on-chain-transaction-history.component.ts @@ -36,7 +36,7 @@ export class ECLOnChainTransactionHistoryComponent implements OnInit, OnDestroy public PAGE_ID = 'on_chain'; public tableSetting: TableSetting = { tableId: 'transaction', recordsPerPage: PAGE_SIZE, sortBy: 'timestamp', sortOrder: SortOrderEnum.DESCENDING }; public displayedColumns: any[] = []; - public listTransactions: any; + public listTransactions: any = new MatTableDataSource([]); public pageSize = PAGE_SIZE; public pageSizeOptions = PAGE_SIZE_OPTIONS; public screenSize = ''; diff --git a/src/app/eclair/peers-channels/channels/channels-tables/channel-inactive-table/channel-inactive-table.component.ts b/src/app/eclair/peers-channels/channels/channels-tables/channel-inactive-table/channel-inactive-table.component.ts index 75b8a37c..2a509e18 100644 --- a/src/app/eclair/peers-channels/channels/channels-tables/channel-inactive-table/channel-inactive-table.component.ts +++ b/src/app/eclair/peers-channels/channels/channels-tables/channel-inactive-table/channel-inactive-table.component.ts @@ -40,7 +40,7 @@ export class ECLChannelInactiveTableComponent implements OnInit, AfterViewInit, public inactiveChannels: Channel[]; public totalBalance = 0; public displayedColumns: any[] = []; - public channels: any; + public channels: any = new MatTableDataSource([]); public myChanPolicy: any = {}; public information: GetInfo = {}; public numPeers = -1; diff --git a/src/app/eclair/peers-channels/channels/channels-tables/channel-open-table/channel-open-table.component.ts b/src/app/eclair/peers-channels/channels/channels-tables/channel-open-table/channel-open-table.component.ts index 71e020cc..b8deb44a 100644 --- a/src/app/eclair/peers-channels/channels/channels-tables/channel-open-table/channel-open-table.component.ts +++ b/src/app/eclair/peers-channels/channels/channels-tables/channel-open-table/channel-open-table.component.ts @@ -41,7 +41,7 @@ export class ECLChannelOpenTableComponent implements OnInit, AfterViewInit, OnDe public activeChannels: Channel[]; public totalBalance = 0; public displayedColumns: any[] = []; - public channels: any; + public channels: any = new MatTableDataSource([]); public myChanPolicy: any = {}; public information: GetInfo = {}; public numPeers = -1; diff --git a/src/app/eclair/peers-channels/channels/channels-tables/channel-pending-table/channel-pending-table.component.ts b/src/app/eclair/peers-channels/channels/channels-tables/channel-pending-table/channel-pending-table.component.ts index 14fcb32f..2dd29bae 100644 --- a/src/app/eclair/peers-channels/channels/channels-tables/channel-pending-table/channel-pending-table.component.ts +++ b/src/app/eclair/peers-channels/channels/channels-tables/channel-pending-table/channel-pending-table.component.ts @@ -40,7 +40,7 @@ export class ECLChannelPendingTableComponent implements OnInit, AfterViewInit, O public pendingChannels: Channel[]; public totalBalance = 0; public displayedColumns: any[] = []; - public channels: any; + public channels: any = new MatTableDataSource([]); public myChanPolicy: any = {}; public information: GetInfo = {}; public numPeers = -1; diff --git a/src/app/eclair/peers-channels/peers/peers.component.ts b/src/app/eclair/peers-channels/peers/peers.component.ts index 03bce18a..6e648411 100644 --- a/src/app/eclair/peers-channels/peers/peers.component.ts +++ b/src/app/eclair/peers-channels/peers/peers.component.ts @@ -43,7 +43,7 @@ export class ECLPeersComponent implements OnInit, AfterViewInit, OnDestroy { public displayedColumns: any[] = []; public peerAddress: string | null = ''; public peersData: Peer[] = []; - public peers: any; + public peers: any = new MatTableDataSource([]); public information: GetInfo = {}; public availableBalance = 0; public pageSize = PAGE_SIZE; diff --git a/src/app/eclair/routing/forwarding-history/forwarding-history.component.ts b/src/app/eclair/routing/forwarding-history/forwarding-history.component.ts index 13c2a582..206e98c0 100644 --- a/src/app/eclair/routing/forwarding-history/forwarding-history.component.ts +++ b/src/app/eclair/routing/forwarding-history/forwarding-history.component.ts @@ -36,7 +36,7 @@ export class ECLForwardingHistoryComponent implements OnInit, OnChanges, AfterVi @Input() filterValue = ''; public tableSetting: TableSetting = { tableId: 'forwarding_history', recordsPerPage: PAGE_SIZE, sortBy: 'timestamp', sortOrder: SortOrderEnum.DESCENDING }; public displayedColumns: any[] = []; - public forwardingHistoryEvents: any; + public forwardingHistoryEvents: any = new MatTableDataSource([]); public pageSize = PAGE_SIZE; public pageSizeOptions = PAGE_SIZE_OPTIONS; public screenSize = ''; diff --git a/src/app/eclair/routing/routing-peers/routing-peers.component.ts b/src/app/eclair/routing/routing-peers/routing-peers.component.ts index ce7dd592..9b3c1710 100644 --- a/src/app/eclair/routing/routing-peers/routing-peers.component.ts +++ b/src/app/eclair/routing/routing-peers/routing-peers.component.ts @@ -34,8 +34,8 @@ export class ECLRoutingPeersComponent implements OnInit, AfterViewInit, OnDestro public tableSetting: TableSetting = { tableId: 'routing_peers', recordsPerPage: PAGE_SIZE, sortBy: 'totalFee', sortOrder: SortOrderEnum.DESCENDING }; public routingPeersData: PaymentRelayed[] = []; public displayedColumns: any[] = []; - public RoutingPeersIncoming: any; - public RoutingPeersOutgoing: any; + public RoutingPeersIncoming: any = new MatTableDataSource([]); + public RoutingPeersOutgoing: any = new MatTableDataSource([]); public pageSize = PAGE_SIZE; public pageSizeOptions = PAGE_SIZE_OPTIONS; public screenSize = ''; diff --git a/src/app/eclair/transactions/create-invoice-modal/create-invoice.component.ts b/src/app/eclair/transactions/create-invoice-modal/create-invoice.component.ts index e932462a..86d2d6a7 100644 --- a/src/app/eclair/transactions/create-invoice-modal/create-invoice.component.ts +++ b/src/app/eclair/transactions/create-invoice-modal/create-invoice.component.ts @@ -31,7 +31,6 @@ export class ECLCreateInvoiceComponent implements OnInit, OnDestroy { public invoiceValue: number | null = null; public invoiceValueHint = ''; public invoicePaymentReq = ''; - public invoices: any; public information: GetInfo = {}; public private = false; public expiryStep = 100; diff --git a/src/app/eclair/transactions/invoices/lightning-invoices.component.ts b/src/app/eclair/transactions/invoices/lightning-invoices.component.ts index 81cf758d..c81b2354 100644 --- a/src/app/eclair/transactions/invoices/lightning-invoices.component.ts +++ b/src/app/eclair/transactions/invoices/lightning-invoices.component.ts @@ -50,7 +50,7 @@ export class ECLLightningInvoicesComponent implements OnInit, AfterViewInit, OnD public invoiceValueHint = ''; public displayedColumns: any[] = []; public invoicePaymentReq = ''; - public invoices: any; + public invoices: any = new MatTableDataSource([]); public invoiceJSONArr: Invoice[] = []; public information: GetInfo = {}; public selFilter = ''; diff --git a/src/app/lnd/backup/channel-backup-table/channel-backup-table.component.ts b/src/app/lnd/backup/channel-backup-table/channel-backup-table.component.ts index 2e6afa8b..3e94c306 100644 --- a/src/app/lnd/backup/channel-backup-table/channel-backup-table.component.ts +++ b/src/app/lnd/backup/channel-backup-table/channel-backup-table.component.ts @@ -42,7 +42,7 @@ export class ChannelBackupTableComponent implements OnInit, AfterViewInit, OnDes public displayedColumns = ['channel_point', 'actions']; public selectedChannel: Channel | null; public channelsData: Channel[] = []; - public channels: any; + public channels: any = new MatTableDataSource([]); public screenSize = ''; public screenSizeEnum = ScreenSizeEnum; public errorMessage = ''; diff --git a/src/app/lnd/backup/channel-restore-table/channel-restore-table.component.ts b/src/app/lnd/backup/channel-restore-table/channel-restore-table.component.ts index 1a309d68..44ff398e 100644 --- a/src/app/lnd/backup/channel-restore-table/channel-restore-table.component.ts +++ b/src/app/lnd/backup/channel-restore-table/channel-restore-table.component.ts @@ -35,7 +35,7 @@ export class ChannelRestoreTableComponent implements OnInit, AfterViewInit, OnDe public displayedColumns = ['channel_point', 'actions']; public selChannel: Channel; public channelsData = []; - public channels: any; + public channels: any = new MatTableDataSource([]); public allRestoreExists = false; public flgLoading: Array = [true]; // 0: channels public selFilter = ''; diff --git a/src/app/lnd/graph/lookups/lookups.component.ts b/src/app/lnd/graph/lookups/lookups.component.ts index 38fca255..dacae9db 100644 --- a/src/app/lnd/graph/lookups/lookups.component.ts +++ b/src/app/lnd/graph/lookups/lookups.component.ts @@ -22,7 +22,6 @@ export class LookupsComponent implements OnInit, OnDestroy { public lookupKey = ''; public lookupValue = {}; public flgSetLookupValue = false; - public temp: any; public messageObj = []; public selectedFieldId = 0; public lookupFields = [ diff --git a/src/app/lnd/graph/query-routes/query-routes.component.ts b/src/app/lnd/graph/query-routes/query-routes.component.ts index abbac3cf..960074ca 100644 --- a/src/app/lnd/graph/query-routes/query-routes.component.ts +++ b/src/app/lnd/graph/query-routes/query-routes.component.ts @@ -31,7 +31,7 @@ export class QueryRoutesComponent implements OnInit, OnDestroy { public tableSetting: TableSetting = { tableId: 'query_routes', recordsPerPage: PAGE_SIZE, sortBy: 'hop_sequence', sortOrder: SortOrderEnum.ASCENDING }; public destinationPubkey = ''; public amount = null; - public qrHops: any; + public qrHops: any = new MatTableDataSource([]); public displayedColumns: any[] = []; public flgLoading: Array = [false]; // 0: peers public faRoute = faRoute; diff --git a/src/app/lnd/on-chain/utxo-tables/on-chain-transaction-history/on-chain-transaction-history.component.ts b/src/app/lnd/on-chain/utxo-tables/on-chain-transaction-history/on-chain-transaction-history.component.ts index 67783ae6..5c9d96aa 100644 --- a/src/app/lnd/on-chain/utxo-tables/on-chain-transaction-history/on-chain-transaction-history.component.ts +++ b/src/app/lnd/on-chain/utxo-tables/on-chain-transaction-history/on-chain-transaction-history.component.ts @@ -36,7 +36,7 @@ export class OnChainTransactionHistoryComponent implements OnInit, OnChanges, On public transactions: Transaction[]; public faHistory = faHistory; public displayedColumns: any[] = []; - public listTransactions: any; + public listTransactions: any = new MatTableDataSource([]); public pageSize = PAGE_SIZE; public pageSizeOptions = PAGE_SIZE_OPTIONS; public screenSize = ''; diff --git a/src/app/lnd/on-chain/utxo-tables/utxos/utxos.component.ts b/src/app/lnd/on-chain/utxo-tables/utxos/utxos.component.ts index 487032a5..b3aaf31d 100644 --- a/src/app/lnd/on-chain/utxo-tables/utxos/utxos.component.ts +++ b/src/app/lnd/on-chain/utxo-tables/utxos/utxos.component.ts @@ -44,7 +44,7 @@ export class OnChainUTXOsComponent implements OnInit, OnChanges, OnDestroy { public dustUtxos: UTXO[]; public addressType = WALLET_ADDRESS_TYPE; public displayedColumns: any[] = []; - public listUTXOs: any; + public listUTXOs: any = new MatTableDataSource([]); public pageSize = PAGE_SIZE; public pageSizeOptions = PAGE_SIZE_OPTIONS; public screenSize = ''; diff --git a/src/app/lnd/peers-channels/channels/channels-tables/channel-active-htlcs-table/channel-active-htlcs-table.component.ts b/src/app/lnd/peers-channels/channels/channels-tables/channel-active-htlcs-table/channel-active-htlcs-table.component.ts index 65dca20b..0a9ecd5f 100644 --- a/src/app/lnd/peers-channels/channels/channels-tables/channel-active-htlcs-table/channel-active-htlcs-table.component.ts +++ b/src/app/lnd/peers-channels/channels/channels-tables/channel-active-htlcs-table/channel-active-htlcs-table.component.ts @@ -32,7 +32,7 @@ export class ChannelActiveHTLCsTableComponent implements OnInit, AfterViewInit, @ViewChild(MatPaginator, { static: false }) paginator: MatPaginator | undefined; public PAGE_ID = 'peers_channels'; public tableSetting: TableSetting = { tableId: 'active_HTLCs', recordsPerPage: PAGE_SIZE, sortBy: 'expiration_height', sortOrder: SortOrderEnum.DESCENDING }; - public channels: any; + public channels: any = new MatTableDataSource([]); public channelsJSONArr: Channel[] = []; public displayedColumns: any[] = []; public htlcColumns = []; diff --git a/src/app/lnd/peers-channels/channels/channels-tables/channel-closed-table/channel-closed-table.component.ts b/src/app/lnd/peers-channels/channels/channels-tables/channel-closed-table/channel-closed-table.component.ts index 41916eda..c39fa19d 100644 --- a/src/app/lnd/peers-channels/channels/channels-tables/channel-closed-table/channel-closed-table.component.ts +++ b/src/app/lnd/peers-channels/channels/channels-tables/channel-closed-table/channel-closed-table.component.ts @@ -36,7 +36,7 @@ export class ChannelClosedTableComponent implements OnInit, AfterViewInit, OnDes public faHistory = faHistory; public displayedColumns: any[] = []; public closedChannelsData: ClosedChannel[] = []; - public closedChannels: any; + public closedChannels: any = new MatTableDataSource([]); public pageSize = PAGE_SIZE; public pageSizeOptions = PAGE_SIZE_OPTIONS; public screenSize = ''; diff --git a/src/app/lnd/peers-channels/channels/channels-tables/channel-open-table/channel-open-table.component.ts b/src/app/lnd/peers-channels/channels/channels-tables/channel-open-table/channel-open-table.component.ts index ad4d2778..8d64e83f 100644 --- a/src/app/lnd/peers-channels/channels/channels-tables/channel-open-table/channel-open-table.component.ts +++ b/src/app/lnd/peers-channels/channels/channels-tables/channel-open-table/channel-open-table.component.ts @@ -49,7 +49,7 @@ export class ChannelOpenTableComponent implements OnInit, AfterViewInit, OnDestr public totalBalance = 0; public displayedColumns: any[] = []; public channelsData: Channel[] = []; - public channels: any; + public channels: any = new MatTableDataSource([]); public myChanPolicy: any = {}; public information: GetInfo = {}; public numPeers = -1; diff --git a/src/app/lnd/peers-channels/peers/peers.component.ts b/src/app/lnd/peers-channels/peers/peers.component.ts index 3ff54bcc..0b761635 100644 --- a/src/app/lnd/peers-channels/peers/peers.component.ts +++ b/src/app/lnd/peers-channels/peers/peers.component.ts @@ -40,7 +40,7 @@ export class PeersComponent implements OnInit, AfterViewInit, OnDestroy { public faUsers = faUsers; public displayedColumns: any[] = []; public peersData: Peer[] = []; - public peers: any; + public peers: any = new MatTableDataSource([]); public information: GetInfo = {}; public pageSize = PAGE_SIZE; public pageSizeOptions = PAGE_SIZE_OPTIONS; diff --git a/src/app/lnd/routing/forwarding-history/forwarding-history.component.ts b/src/app/lnd/routing/forwarding-history/forwarding-history.component.ts index 0370489e..1edcd456 100644 --- a/src/app/lnd/routing/forwarding-history/forwarding-history.component.ts +++ b/src/app/lnd/routing/forwarding-history/forwarding-history.component.ts @@ -38,7 +38,7 @@ export class ForwardingHistoryComponent implements OnInit, AfterViewInit, OnChan public tableSetting: TableSetting = { tableId: 'forwarding_history', recordsPerPage: PAGE_SIZE, sortBy: 'timestamp', sortOrder: SortOrderEnum.DESCENDING }; public forwardingHistoryData: ForwardingEvent[] = []; public displayedColumns: any[] = []; - public forwardingHistoryEvents: any; + public forwardingHistoryEvents: any = new MatTableDataSource([]); public pageSize = PAGE_SIZE; public pageSizeOptions = PAGE_SIZE_OPTIONS; public screenSize = ''; diff --git a/src/app/lnd/transactions/create-invoice-modal/create-invoice.component.ts b/src/app/lnd/transactions/create-invoice-modal/create-invoice.component.ts index 661eaaca..ea680b86 100644 --- a/src/app/lnd/transactions/create-invoice-modal/create-invoice.component.ts +++ b/src/app/lnd/transactions/create-invoice-modal/create-invoice.component.ts @@ -31,7 +31,6 @@ export class CreateInvoiceComponent implements OnInit, OnDestroy { public invoiceValue: number | null; public invoiceValueHint = ''; public invoicePaymentReq = ''; - public invoices: any; public information: GetInfo = {}; public private = false; public expiryStep = 100; diff --git a/src/app/lnd/transactions/lookup-transactions/lookup-transactions.component.ts b/src/app/lnd/transactions/lookup-transactions/lookup-transactions.component.ts index c1bf4c14..ae7dc163 100644 --- a/src/app/lnd/transactions/lookup-transactions/lookup-transactions.component.ts +++ b/src/app/lnd/transactions/lookup-transactions/lookup-transactions.component.ts @@ -22,7 +22,6 @@ export class LookupTransactionsComponent implements OnInit, OnDestroy { public lookupKey = ''; public lookupValue = {}; public flgSetLookupValue = false; - public temp: any; public messageObj = []; public selectedFieldId = 0; public lookupFields = [ diff --git a/src/app/lnd/transactions/payments/lightning-payments.component.ts b/src/app/lnd/transactions/payments/lightning-payments.component.ts index 3c959c32..3ea38411 100644 --- a/src/app/lnd/transactions/payments/lightning-payments.component.ts +++ b/src/app/lnd/transactions/payments/lightning-payments.component.ts @@ -47,7 +47,7 @@ export class LightningPaymentsComponent implements OnInit, AfterViewInit, OnDest public selNode: SelNodeChild | null = {}; public information: GetInfo = {}; public peers: Peer[] = []; - public payments: any; + public payments: any = new MatTableDataSource([]); public totalPayments = 100; public paymentJSONArr: Payment[] = []; public displayedColumns: any[] = []; diff --git a/src/app/shared/components/ln-services/boltz/swaps/swaps.component.ts b/src/app/shared/components/ln-services/boltz/swaps/swaps.component.ts index d6303c7c..eb5828b8 100755 --- a/src/app/shared/components/ln-services/boltz/swaps/swaps.component.ts +++ b/src/app/shared/components/ln-services/boltz/swaps/swaps.component.ts @@ -42,7 +42,7 @@ export class BoltzSwapsComponent implements OnInit, AfterViewInit, OnChanges, On public faHistory = faHistory; public swapCaption = 'Swap Out'; public displayedColumns: any[] = []; - public listSwaps: any; + public listSwaps: any = new MatTableDataSource([]); public selFilter = ''; public pageSize = PAGE_SIZE; public pageSizeOptions = PAGE_SIZE_OPTIONS; diff --git a/src/app/shared/components/ln-services/loop/swaps/swaps.component.ts b/src/app/shared/components/ln-services/loop/swaps/swaps.component.ts index 5e760ba9..bc50354c 100755 --- a/src/app/shared/components/ln-services/loop/swaps/swaps.component.ts +++ b/src/app/shared/components/ln-services/loop/swaps/swaps.component.ts @@ -41,7 +41,7 @@ export class SwapsComponent implements OnInit, AfterViewInit, OnChanges, OnDestr public faHistory = faHistory; public swapCaption = 'Loop Out'; public displayedColumns: any[] = []; - public listSwaps: any; + public listSwaps: any = new MatTableDataSource([]); public selFilter = ''; public pageSize = PAGE_SIZE; public pageSizeOptions = PAGE_SIZE_OPTIONS; diff --git a/src/app/shared/components/transactions-report-table/transactions-report-table.component.ts b/src/app/shared/components/transactions-report-table/transactions-report-table.component.ts index 65c7ed19..516e6b57 100644 --- a/src/app/shared/components/transactions-report-table/transactions-report-table.component.ts +++ b/src/app/shared/components/transactions-report-table/transactions-report-table.component.ts @@ -31,7 +31,7 @@ export class TransactionsReportTableComponent implements OnInit, AfterViewInit, @ViewChild(MatPaginator, { static: false }) paginator: MatPaginator | undefined; public timezoneOffset = new Date(Date.now()).getTimezoneOffset() * 60; public scrollRanges = SCROLL_RANGES; - public transactions: any; + public transactions: any = new MatTableDataSource([]); public pageSize = PAGE_SIZE; public pageSizeOptions = PAGE_SIZE_OPTIONS; public screenSize = '';