Improve storage
This commit is contained in:
@ -92,10 +92,8 @@ struct AddFileView: View {
|
||||
continue
|
||||
}
|
||||
if let url = file.url {
|
||||
do {
|
||||
try content.storage.copyFile(at: url, fileId: file.uniqueId)
|
||||
} catch {
|
||||
print("Failed to import file '\(file.uniqueId)' at \(url.path()): \(error)")
|
||||
guard content.storage.importExternalFile(at: url, fileId: file.uniqueId) else {
|
||||
print("Failed to import file '\(file.uniqueId)' at \(url.path())")
|
||||
return
|
||||
}
|
||||
}
|
||||
|
Reference in New Issue
Block a user