feat(amznmusic): add prevent log upload patch
This commit is contained in:
parent
dc39dfdab4
commit
2d7cf86bfd
1 changed files with 20 additions and 0 deletions
|
|
@ -0,0 +1,20 @@
|
||||||
|
package app.revanced.patches.amznmusic.misc.uploadlogs
|
||||||
|
|
||||||
|
import app.revanced.patcher.firstClassDef
|
||||||
|
import app.revanced.patcher.firstMethod
|
||||||
|
import app.revanced.patcher.patch.bytecodePatch
|
||||||
|
import app.revanced.util.returnEarly
|
||||||
|
|
||||||
|
@Suppress("unused")
|
||||||
|
val preventUploadLogsPatch = bytecodePatch(
|
||||||
|
name = "Prevent log upload",
|
||||||
|
description = "Avoid uploading logs when the application crashes.",
|
||||||
|
) {
|
||||||
|
compatibleWith("com.amazon.mp3")
|
||||||
|
|
||||||
|
apply {
|
||||||
|
var pendingCrashLogsClass = firstClassDef { type == "Lcom/amazon/mp3/det/PendingCrashLogs;" }
|
||||||
|
pendingCrashLogsClass.firstMethod { name == "uploadLogAfterCrash" }.returnEarly()
|
||||||
|
pendingCrashLogsClass.firstMethod { name == "uploadPendingCrashLogsIfRequired" }.returnEarly()
|
||||||
|
}
|
||||||
|
}
|
||||||
Loading…
Add table
Add a link
Reference in a new issue