From 05705b1dec12fd3351a891067532a6507bc4fd70 Mon Sep 17 00:00:00 2001 From: Martin Filo Date: Sun, 11 Jun 2023 20:02:09 +0200 Subject: [PATCH] fix: add remote sync capability - fix icon backup import from older versions --- .../com/lagradost/cloudstream3/utils/BackupUtils.kt | 13 +++++++++++-- 1 file changed, 11 insertions(+), 2 deletions(-) diff --git a/app/src/main/java/com/lagradost/cloudstream3/utils/BackupUtils.kt b/app/src/main/java/com/lagradost/cloudstream3/utils/BackupUtils.kt index 27c110d3..14447113 100644 --- a/app/src/main/java/com/lagradost/cloudstream3/utils/BackupUtils.kt +++ b/app/src/main/java/com/lagradost/cloudstream3/utils/BackupUtils.kt @@ -108,12 +108,21 @@ object BackupUtils { @JsonProperty("_Float") val _Float: Map?, @JsonProperty("_Long") val _Long: Map?, @JsonProperty("_StringSet") val _StringSet: Map?>?, - ) + ) { + constructor() : this( + mapOf(), + mapOf(), + mapOf(), + mapOf(), + mapOf(), + mapOf(), + ) + } data class BackupFile( @JsonProperty("datastore") val datastore: BackupVars, @JsonProperty("settings") val settings: BackupVars, - @JsonProperty("sync-meta") val syncMeta: BackupVars, + @JsonProperty("sync-meta") val syncMeta: BackupVars = BackupVars(), ) { fun restore( ctx: Context,