@@ -368,12 +368,8 @@ class LightningService {
368368 return false
369369 }
370370
371- // When geoblocked, only count non-LSP channels
372- let isGeoblocked = GeoService . shared. isGeoBlocked
373- let channelsToUse = isGeoblocked ? getNonLspChannels ( ) : channels
374-
375371 let totalNextOutboundHtlcLimitSats =
376- channelsToUse
372+ channels
377373 . filter ( \. isUsable)
378374 . map ( \. nextOutboundHtlcLimitMsat)
379375 . reduce ( 0 , + ) / 1000
@@ -436,16 +432,6 @@ class LightningService {
436432 throw AppError ( serviceError: . nodeNotSetup)
437433 }
438434
439- // When geoblocked, verify we have external (non-LSP) peers
440- let isGeoblocked = GeoService . shared. isGeoBlocked
441- if isGeoblocked && !hasExternalPeers( ) {
442- Logger . error ( " Cannot send Lightning payment when geoblocked without external peers " )
443- throw AppError (
444- message: " Lightning send unavailable " ,
445- debugMessage: " You need channels with non-Blocktank nodes to send Lightning payments. "
446- )
447- }
448-
449435 Logger . info ( " Paying bolt11: \( bolt11) " )
450436
451437 do {
@@ -657,31 +643,6 @@ extension LightningService {
657643 try node. getAddressBalance ( addressStr: address)
658644 }
659645 }
660-
661- /// Returns LSP (Blocktank) peer node IDs
662- func getLspPeerNodeIds( ) -> [ String ] {
663- return Env . trustedLnPeers. map ( \. nodeId)
664- }
665-
666- /// Checks if there are connected peers other than LSP peers
667- /// Used for geoblocking to determine if Lightning operations can proceed
668- func hasExternalPeers( ) -> Bool {
669- guard let peers else { return false }
670- let lspNodeIds = Set ( getLspPeerNodeIds ( ) )
671- return peers. contains { peer in
672- !lspNodeIds. contains ( peer. nodeId)
673- }
674- }
675-
676- /// Filters channels to exclude LSP channels
677- /// Used for geoblocking to only allow operations through non-Blocktank channels
678- func getNonLspChannels( ) -> [ ChannelDetails ] {
679- guard let channels else { return [ ] }
680- let lspNodeIds = Set ( getLspPeerNodeIds ( ) )
681- return channels. filter { channel in
682- !lspNodeIds. contains ( channel. counterpartyNodeId)
683- }
684- }
685646}
686647
687648// MARK: Events
0 commit comments