Avoid logging warning why attempting to delete unexisting file.
This commit is contained in:
committed by
Benoit Marty
parent
f2900de7af
commit
4fa1327925
@@ -25,6 +25,7 @@ import java.util.Locale
|
||||
import java.util.UUID
|
||||
|
||||
fun File.safeDelete() {
|
||||
if (exists().not()) return
|
||||
tryOrNull(
|
||||
onError = {
|
||||
Timber.e(it, "Error, unable to delete file $path")
|
||||
|
||||
Reference in New Issue
Block a user