chore(syncforreddit/change-oauth-client-id): revert using downloads directory

This commit is contained in:
oSumAtrIX 2023-06-12 23:21:20 +02:00
parent 8f673da7c9
commit 18ec8f46dd
No known key found for this signature in database
GPG key ID: A9B3094ACDB604B4
2 changed files with 2 additions and 7 deletions

View file

@ -3,9 +3,7 @@ package android.os;
import java.io.File; import java.io.File;
public final class Environment { public final class Environment {
public static String DIRECTORY_DOWNLOADS = "Download"; public static File getExternalStorageDirectory() {
public static File getExternalStoragePublicDirectory(final String type) {
throw new UnsupportedOperationException("Stub"); throw new UnsupportedOperationException("Stub");
} }
} }

View file

@ -39,10 +39,7 @@ class ChangeOAuthClientIdPatch : BytecodePatch(
return PatchResultError("No client ID provided") return PatchResultError("No client ID provided")
} }
File( File(Environment.getExternalStorageDirectory(), "reddit_client_id_revanced.txt").also {
Environment.getExternalStoragePublicDirectory(Environment.DIRECTORY_DOWNLOADS),
"reddit_client_id_revanced.txt"
).also {
if (it.exists()) return@also if (it.exists()) return@also
val error = """ val error = """