mirror of
https://github.com/nextcloud/android.git
synced 2024-11-29 10:49:04 +03:00
Fix database migration of field forceOverwrite to NameCollisionPolicy
Signed-off-by: Alice Gaudon <alice@gaudon.pro>
This commit is contained in:
parent
52d089b18a
commit
91ef307e7a
2 changed files with 6 additions and 3 deletions
|
@ -1053,10 +1053,13 @@ public class FileUploader extends Service
|
|||
}
|
||||
|
||||
|
||||
/**
|
||||
* Ordinal of enumerated constants is important for old data compatibility.
|
||||
*/
|
||||
public enum NameCollisionPolicy {
|
||||
RENAME, // Ordinal corresponds to old forceOverwrite = false (0 in database)
|
||||
OVERWRITE, // Ordinal corresponds to old forceOverwrite = true (1 in database)
|
||||
CANCEL,
|
||||
RENAME,
|
||||
OVERWRITE,
|
||||
ASK_USER;
|
||||
|
||||
public static final NameCollisionPolicy DEFAULT = RENAME;
|
||||
|
|
|
@ -2147,7 +2147,7 @@ public class FileContentProvider extends ContentProvider {
|
|||
ProviderTableMeta.UPLOADS_STATUS + ", " +
|
||||
ProviderTableMeta.UPLOADS_LOCAL_BEHAVIOUR + ", " +
|
||||
ProviderTableMeta.UPLOADS_UPLOAD_TIME + ", " +
|
||||
"force_overwrite" + ", " +
|
||||
"force_overwrite" + ", " + // See FileUploader.NameCollisionPolicy
|
||||
ProviderTableMeta.UPLOADS_IS_CREATE_REMOTE_FOLDER + ", " +
|
||||
ProviderTableMeta.UPLOADS_UPLOAD_END_TIMESTAMP + ", " +
|
||||
ProviderTableMeta.UPLOADS_LAST_RESULT + ", " +
|
||||
|
|
Loading…
Reference in a new issue