diff options
author | pacien | 2023-07-29 23:32:28 +0200 |
---|---|---|
committer | pacien | 2023-07-30 03:53:20 +0200 |
commit | 564e675c0a44dfb3b914d1d4307fdde844ad082f (patch) | |
tree | 9889a0f68e8277d807165a8d4d4b6533cd009998 /app/src/main/java/org/pacien/tincapp/context/ConfigurationDirectoryMigrator.kt | |
parent | dfb26a0d2c95d56f69f5e1e0c255d9d5d6788120 (diff) | |
download | tincapp-564e675c0a44dfb3b914d1d4307fdde844ad082f.tar.gz |
storage: move app and tinc daemon logs to user-accessible cache directory
Diffstat (limited to 'app/src/main/java/org/pacien/tincapp/context/ConfigurationDirectoryMigrator.kt')
-rw-r--r-- | app/src/main/java/org/pacien/tincapp/context/ConfigurationDirectoryMigrator.kt | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/app/src/main/java/org/pacien/tincapp/context/ConfigurationDirectoryMigrator.kt b/app/src/main/java/org/pacien/tincapp/context/ConfigurationDirectoryMigrator.kt index 0fedf6f..ea0b7d8 100644 --- a/app/src/main/java/org/pacien/tincapp/context/ConfigurationDirectoryMigrator.kt +++ b/app/src/main/java/org/pacien/tincapp/context/ConfigurationDirectoryMigrator.kt | |||
@@ -1,6 +1,6 @@ | |||
1 | /* | 1 | /* |
2 | * Tinc App, an Android binding and user interface for the tinc mesh VPN daemon | 2 | * Tinc App, an Android binding and user interface for the tinc mesh VPN daemon |
3 | * Copyright (C) 2017-2020 Pacien TRAN-GIRARD | 3 | * Copyright (C) 2017-2023 Pacien TRAN-GIRARD |
4 | * | 4 | * |
5 | * This program is free software: you can redistribute it and/or modify | 5 | * This program is free software: you can redistribute it and/or modify |
6 | * it under the terms of the GNU General Public License as published by | 6 | * it under the terms of the GNU General Public License as published by |
@@ -56,7 +56,7 @@ class ConfigurationDirectoryMigrator { | |||
56 | } | 56 | } |
57 | 57 | ||
58 | private fun migrateLogDirectory() { | 58 | private fun migrateLogDirectory() { |
59 | val oldLogDir = context.externalCacheDir | 59 | val oldLogDir = context.cacheDir |
60 | if (oldLogDir == null || oldLogDir.listFiles().isNullOrEmpty()) return // nothing to do | 60 | if (oldLogDir == null || oldLogDir.listFiles().isNullOrEmpty()) return // nothing to do |
61 | 61 | ||
62 | try { | 62 | try { |