Skip to content
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
@@ -1,6 +1,5 @@
package com.lagradost.cloudstream3.utils

import android.annotation.SuppressLint
import android.content.Context
import android.net.Uri
import android.widget.Toast
Expand Down Expand Up @@ -40,6 +39,7 @@ import java.io.PrintWriter
import java.lang.System.currentTimeMillis
import java.text.SimpleDateFormat
import java.util.Date
import java.util.Locale

object BackupUtils {

Expand Down Expand Up @@ -164,7 +164,6 @@ object BackupUtils {
}
}

@SuppressLint("SimpleDateFormat")
fun backup(context: Context?) = ioSafe {
if (context == null) return@ioSafe

Expand All @@ -177,7 +176,7 @@ object BackupUtils {
return@ioSafe
}

val date = SimpleDateFormat("yyyy_MM_dd_HH_mm").format(Date(currentTimeMillis()))
val date = SimpleDateFormat("yyyy_MM_dd_HH_mm", Locale.getDefault()).format(Date(currentTimeMillis()))
val displayName = "CS3_Backup_${date}"
val backupFile = getBackup(context)
val stream = setupBackupStream(context, displayName)
Expand Down