From fb0a9262c09204cf1efc78458df9462dd1cc0467 Mon Sep 17 00:00:00 2001 From: Davide Date: Mon, 11 Nov 2024 16:11:09 +0100 Subject: [PATCH] Fix double reload of selected provider server (#851) Skip initial nil filter, overlaps with initial .reloadServers() in task. Fixes #850 --- .../AppUIMain/Views/Provider/VPNProviderServerView.swift | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Passepartout/Library/Sources/AppUIMain/Views/Provider/VPNProviderServerView.swift b/Passepartout/Library/Sources/AppUIMain/Views/Provider/VPNProviderServerView.swift index 7bceb419..2e93a874 100644 --- a/Passepartout/Library/Sources/AppUIMain/Views/Provider/VPNProviderServerView.swift +++ b/Passepartout/Library/Sources/AppUIMain/Views/Provider/VPNProviderServerView.swift @@ -166,7 +166,7 @@ extension VPNProviderServerView { errorHandler.handle(error, title: Strings.Global.servers) } } - .onReceive(filtersViewModel.$filters) { newValue in + .onReceive(filtersViewModel.$filters.dropFirst()) { newValue in Task { await reloadServers(filters: newValue) }