From e912442a71e99b53cc2babf4f2c65061a0d35b05 Mon Sep 17 00:00:00 2001 From: tibbi Date: Thu, 16 Mar 2017 22:56:35 +0100 Subject: [PATCH] add the timestamp to exported database name --- .../com/simplemobiletools/calendar/activities/MainActivity.kt | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/app/src/main/kotlin/com/simplemobiletools/calendar/activities/MainActivity.kt b/app/src/main/kotlin/com/simplemobiletools/calendar/activities/MainActivity.kt index 011ff9333..1f2f0fd3c 100644 --- a/app/src/main/kotlin/com/simplemobiletools/calendar/activities/MainActivity.kt +++ b/app/src/main/kotlin/com/simplemobiletools/calendar/activities/MainActivity.kt @@ -245,7 +245,7 @@ class MainActivity : SimpleActivity(), NavigationListener { private fun exportDatabase() { FilePickerDialog(this, pickFile = false) { val source = getDatabasePath(DBHelper.DB_NAME) - val destination = File(it, DBHelper.DB_NAME) + val destination = File(it, "calendar_${System.currentTimeMillis()}.db") handleSAFDialog(destination) { Thread({ if (source.exists()) {