File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -138,20 +138,20 @@ class WalletViewModel: ObservableObject {
138138 }
139139
140140 // If no local migration data, try fetching from RN remote backup (one-time)
141- // if channelMigration == nil {
142- // let (remoteMigration, allRetrieved) = await fetchOrphanedChannelMonitorsIfNeeded(walletIndex: walletIndex)
143- // if let remoteMigration {
144- // channelMigration = ChannelDataMigration(
145- // // don't overwrite channel manager, we only need the monitors for the sweep
146- // channelManager: nil,
147- // channelMonitors: remoteMigration.channelMonitors.map { [UInt8]($0) }
148- // )
149- // MigrationsService.shared.pendingChannelMigration = nil
150- // }
151- // if allRetrieved {
152- // MigrationsService.shared.isChannelRecoveryChecked = true
153- // }
154- // }
141+ if channelMigration == nil {
142+ let ( remoteMigration, allRetrieved) = await fetchOrphanedChannelMonitorsIfNeeded ( walletIndex: walletIndex)
143+ if let remoteMigration {
144+ channelMigration = ChannelDataMigration (
145+ // don't overwrite channel manager, we only need the monitors for the sweep
146+ channelManager: nil ,
147+ channelMonitors: remoteMigration. channelMonitors. map { [ UInt8] ( $0) }
148+ )
149+ MigrationsService . shared. pendingChannelMigration = nil
150+ }
151+ if allRetrieved {
152+ MigrationsService . shared. isChannelRecoveryChecked = true
153+ }
154+ }
155155
156156 await runLegacyNetworkGraphCleanupIfNeeded ( )
157157
You can’t perform that action at this time.
0 commit comments