mirror of
https://github.com/SimpleMobileTools/Simple-File-Manager.git
synced 2025-06-05 22:09:15 +02:00
fix some file operations without having SD card
This commit is contained in:
@ -35,7 +35,7 @@ class Utils {
|
|||||||
return matcher.matches()
|
return matcher.matches()
|
||||||
}
|
}
|
||||||
|
|
||||||
fun needsStupidWritePermissions(context: Context, path: String) = isPathOnSD(context, path) && isKitkat()
|
fun needsStupidWritePermissions(context: Context, path: String) = isPathOnSD(context, path) && isKitkat() && !context.getSDCardPath().isEmpty()
|
||||||
|
|
||||||
fun isPathOnSD(context: Context, path: String): Boolean {
|
fun isPathOnSD(context: Context, path: String): Boolean {
|
||||||
return path.startsWith(context.getSDCardPath())
|
return path.startsWith(context.getSDCardPath())
|
||||||
|
Reference in New Issue
Block a user