mirror of
https://github.com/leonboe1/QuickDrop.git
synced 2026-11-19 12:56:06 +00:00
FIx: Cannot save images to photos if custom directory chosen
This commit is contained in:
1 parent
9e7278d327
commit
488f898d7b
3 files changed
+11
-11
No files matched your search
@@ -118,6 +118,11 @@ public class NearbyConnectionManager: NSObject, NetServiceDelegate, InboundNearb
|
||||
}
|
||||
|
||||
|
||||
deinit {
|
||||
self.stopAccessingSaveDirectory()
|
||||
}
|
||||
|
||||
|
||||
public func becomeVisible() {
|
||||
if startedAdvertising {
|
||||
log("[NearbyConnectionManager] Already advertising, skipping")
|
||||
@@ -231,11 +236,6 @@ public class NearbyConnectionManager: NSObject, NetServiceDelegate, InboundNearb
|
||||
func connectionWasTerminated(connection: InboundNearbyConnection, savedFiles: [URL], error: Error?) {
|
||||
incomingConnections.removeValue(forKey: connection.id)
|
||||
|
||||
// If there are no more incoming connections, we can stop accessing the save directory
|
||||
if incomingConnections.isEmpty {
|
||||
self.stopAccessingSaveDirectory()
|
||||
}
|
||||
|
||||
if !connection.wasUserRejected {
|
||||
inboundAppDelegates.forEach { delegate in
|
||||
delegate.connectionWasTerminated(connectionID: connection.id, from: connection.remoteDeviceInfo ?? RemoteDeviceInfo(name: "UnknownDevice".localized(), type: .unknown), savedFiles: savedFiles, wasPlainTextTransfer: connection.isPlainTextTransfer, error: error)
|
||||
|
||||
Reference in new issue
Block a user