fix(syncforreddit/change-oauth-client-id): use downloads directory
This fixes permission errors on Android
This commit is contained in:
parent
b2c7a6a54f
commit
28abefeab0
2 changed files with 7 additions and 2 deletions
|
|
@ -34,7 +34,10 @@ class ChangeOAuthClientIdPatch : BytecodePatch(
|
|||
return PatchResultError("No client ID provided")
|
||||
}
|
||||
|
||||
File(Environment.getExternalStorageDirectory(), "reddit_client_id_revanced.txt").also {
|
||||
File(
|
||||
Environment.getExternalStoragePublicDirectory(Environment.DIRECTORY_DOWNLOADS),
|
||||
"reddit_client_id_revanced.txt"
|
||||
).also {
|
||||
if (it.exists()) return@also
|
||||
|
||||
val error = """
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue