mirror of
https://github.com/permissionlesstech/bitchat.git
synced 2026-07-25 06:45:18 +00:00
Notes icon: force a one-shot location refresh before (re)subscribing the counter so icon turns blue immediately on current 8-cell
This commit is contained in:
@@ -1518,6 +1518,10 @@ extension ContentView {
|
||||
private func updateNotesCounterSubscription() {
|
||||
switch locationManager.selectedChannel {
|
||||
case .mesh:
|
||||
// Ensure we have a fresh one-shot location fix so building geohash is current
|
||||
if locationManager.permissionState == .authorized {
|
||||
LocationChannelManager.shared.refreshChannels()
|
||||
}
|
||||
if let building = LocationChannelManager.shared.availableChannels.first(where: { $0.level == .building })?.geohash {
|
||||
LocationNotesCounter.shared.subscribe(geohash: building)
|
||||
} else {
|
||||
|
||||
Reference in New Issue
Block a user