From feaf557ca2243ff365908f9bbde2bbd6f8bacd53 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Leon=20B=C3=B6ttger?= <49094811+leonboe1@users.noreply.github.com> Date: Fri, 3 Apr 2026 19:19:22 +0200 Subject: [PATCH] Fix outgoing transfer flakiness --- ShareExtension/ShareViewController.swift | 5 +---- 1 file changed, 1 insertion(+), 4 deletions(-) diff --git a/ShareExtension/ShareViewController.swift b/ShareExtension/ShareViewController.swift index 855b954..b885aa5 100644 --- a/ShareExtension/ShareViewController.swift +++ b/ShareExtension/ShareViewController.swift @@ -112,9 +112,7 @@ class ShareViewController: NSViewController, OutboundAppDelegate { timeoutDispatchWorkItem?.cancel() - if chosenDevice == nil { - NearbyConnectionManager.shared.stopDeviceDiscovery() - } + NearbyConnectionManager.shared.stopDeviceDiscovery() NearbyConnectionManager.shared.removeOutboundAppDelegate(self) } @@ -255,7 +253,6 @@ class ShareViewController: NSViewController, OutboundAppDelegate { progressProgressBar?.startAnimation(nil) progressState?.stringValue = "Preparing".localized() chosenDevice = device - NearbyConnectionManager.shared.stopDeviceDiscovery() runAfter(seconds: 0.3) { NearbyConnectionManager.shared.startOutgoingTransfer(deviceID: device.id!, delegate: self, urls: self.urls, textToSend: self.textToSend)