|
@@ -926,7 +926,7 @@ import Queuer
|
|
|
NCManageDatabase.shared.deleteLocalFile(predicate: NSPredicate(format: "ocId == %@", metadata.ocId))
|
|
|
NCUtilityFileSystem.shared.deleteFile(filePath: CCUtility.getDirectoryProviderStorageOcId(metadata.ocId))
|
|
|
|
|
|
- if let metadataLivePhoto = NCManageDatabase.shared.isLivePhoto(metadata: metadata) {
|
|
|
+ if let metadataLivePhoto = NCManageDatabase.shared.getMetadataLivePhoto(metadata: metadata) {
|
|
|
NCManageDatabase.shared.deleteLocalFile(predicate: NSPredicate(format: "ocId == %@", metadataLivePhoto.ocId))
|
|
|
NCUtilityFileSystem.shared.deleteFile(filePath: CCUtility.getDirectoryProviderStorageOcId(metadataLivePhoto.ocId))
|
|
|
}
|
|
@@ -938,7 +938,7 @@ import Queuer
|
|
|
}
|
|
|
|
|
|
let isDirectoryEncrypted = CCUtility.isFolderEncrypted(metadata.serverUrl, e2eEncrypted: metadata.e2eEncrypted, account: metadata.account, urlBase: urlBase)
|
|
|
- let metadataLive = NCManageDatabase.shared.isLivePhoto(metadata: metadata)
|
|
|
+ let metadataLive = NCManageDatabase.shared.getMetadataLivePhoto(metadata: metadata)
|
|
|
|
|
|
if isDirectoryEncrypted {
|
|
|
#if !EXTENSION
|
|
@@ -1006,7 +1006,7 @@ import Queuer
|
|
|
|
|
|
@objc func favoriteMetadata(_ metadata: tableMetadata, urlBase: String, completion: @escaping (_ errorCode: Int, _ errorDescription: String)->()) {
|
|
|
|
|
|
- if let metadataLive = NCManageDatabase.shared.isLivePhoto(metadata: metadata) {
|
|
|
+ if let metadataLive = NCManageDatabase.shared.getMetadataLivePhoto(metadata: metadata) {
|
|
|
favoriteMetadataPlain(metadataLive, urlBase: urlBase) { (errorCode, errorDescription) in
|
|
|
if errorCode == 0 {
|
|
|
self.favoriteMetadataPlain(metadata, urlBase: urlBase, completion: completion)
|
|
@@ -1071,7 +1071,7 @@ import Queuer
|
|
|
@objc func renameMetadata(_ metadata: tableMetadata, fileNameNew: String, urlBase: String, viewController: UIViewController?, completion: @escaping (_ errorCode: Int, _ errorDescription: String?)->()) {
|
|
|
|
|
|
let isDirectoryEncrypted = CCUtility.isFolderEncrypted(metadata.serverUrl, e2eEncrypted: metadata.e2eEncrypted, account: metadata.account, urlBase: urlBase)
|
|
|
- let metadataLive = NCManageDatabase.shared.isLivePhoto(metadata: metadata)
|
|
|
+ let metadataLive = NCManageDatabase.shared.getMetadataLivePhoto(metadata: metadata)
|
|
|
let fileNameNewLive = (fileNameNew as NSString).deletingPathExtension + ".mov"
|
|
|
|
|
|
if isDirectoryEncrypted {
|
|
@@ -1162,7 +1162,7 @@ import Queuer
|
|
|
|
|
|
@objc func moveMetadata(_ metadata: tableMetadata, serverUrlTo: String, overwrite: Bool, completion: @escaping (_ errorCode: Int, _ errorDescription: String?)->()) {
|
|
|
|
|
|
- if let metadataLive = NCManageDatabase.shared.isLivePhoto(metadata: metadata) {
|
|
|
+ if let metadataLive = NCManageDatabase.shared.getMetadataLivePhoto(metadata: metadata) {
|
|
|
moveMetadataPlain(metadataLive, serverUrlTo: serverUrlTo, overwrite: overwrite) { (errorCode, errorDescription) in
|
|
|
if errorCode == 0 {
|
|
|
self.moveMetadataPlain(metadata, serverUrlTo: serverUrlTo, overwrite: overwrite, completion: completion)
|
|
@@ -1208,7 +1208,7 @@ import Queuer
|
|
|
|
|
|
@objc func copyMetadata(_ metadata: tableMetadata, serverUrlTo: String, overwrite: Bool, completion: @escaping (_ errorCode: Int, _ errorDescription: String?)->()) {
|
|
|
|
|
|
- if let metadataLive = NCManageDatabase.shared.isLivePhoto(metadata: metadata) {
|
|
|
+ if let metadataLive = NCManageDatabase.shared.getMetadataLivePhoto(metadata: metadata) {
|
|
|
copyMetadataPlain(metadataLive, serverUrlTo: serverUrlTo, overwrite: overwrite) { (errorCode, errorDescription) in
|
|
|
if errorCode == 0 {
|
|
|
self.copyMetadataPlain(metadata, serverUrlTo: serverUrlTo, overwrite: overwrite, completion: completion)
|