Skip to content

Commit

Permalink
fix(Hide ads): restore compatibility with prior targets
Browse files Browse the repository at this point in the history
  • Loading branch information
LisoUseInAIKyrios committed Jan 11, 2024
1 parent e4b513d commit cc79115
Show file tree
Hide file tree
Showing 2 changed files with 9 additions and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -25,6 +25,12 @@ import com.android.tools.smali.dexlib2.iface.instruction.formats.Instruction35c
compatiblePackages = [
CompatiblePackage(
"com.google.android.youtube", [
"18.32.39",
"18.37.36",
"18.38.44",
"18.43.45",
"18.44.41",
"18.45.43",
"18.48.39",
"18.49.37"
]
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,9 @@ internal object OnBackPressedFingerprint : MethodFingerprint(
Opcode.RETURN_VOID
),
customFingerprint = { methodDef, _ ->
methodDef.definingClass.endsWith("MainActivity;")
(methodDef.definingClass.endsWith("MainActivity;") ||
// Old versions of YouTube called this class "WatchWhileActivity" instead.
methodDef.definingClass.endsWith("WatchWhileActivity;"))
&& methodDef.name == "onBackPressed"
}
)

0 comments on commit cc79115

Please sign in to comment.