mirror of
https://github.com/Swiftgram/Telegram-iOS.git
synced 2025-11-27 18:42:25 +00:00
Various fixes
This commit is contained in:
parent
92eff4727a
commit
f8ebd4aa2f
@ -3087,6 +3087,8 @@ public final class MediaEditorScreen: ViewController, UIDropInteractionDelegate
|
||||
return
|
||||
}
|
||||
|
||||
try? FileManager.default.createDirectory(atPath: draftPath(engine: self.context.engine), withIntermediateDirectories: true)
|
||||
|
||||
let isScopedResource = url.startAccessingSecurityScopedResource()
|
||||
Logger.shared.log("MediaEditor", "isScopedResource = \(isScopedResource)")
|
||||
|
||||
@ -3096,8 +3098,6 @@ public final class MediaEditorScreen: ViewController, UIDropInteractionDelegate
|
||||
let fileName = "audio_\(sourceUrl.lastPathComponent)"
|
||||
let copyPath = fullDraftPath(peerId: self.context.account.peerId, path: fileName)
|
||||
|
||||
Logger.shared.log("MediaEditor", "fileexists = \(FileManager.default.fileExists(atPath: sourceUrl.path))")
|
||||
|
||||
try? FileManager.default.removeItem(atPath: copyPath)
|
||||
do {
|
||||
try FileManager.default.copyItem(at: sourceUrl, to: URL(fileURLWithPath: copyPath))
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user