8000 feat(Cricbuzz): Add `Hide ads` patch by agrawalsourav98 · Pull Request #4998 · ReVanced/revanced-patches · GitHub
[go: up one dir, main page]
More Web Proxy on the site http://driver.im/
Skip to content

feat(Cricbuzz): Add Hide ads patch #4998

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Open
wants to merge 4 commits into
base: dev
Choose a base branch
from

Conversation

agrawalsourav98
Copy link

Add patch to disable ads on cricbuzz app

Copy link
Member
@oSumAtrIX oSumAtrIX left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The patch and fingerprint file should be moved to an "ads" package

@oSumAtrIX oSumAtrIX self-requested a review May 19, 2025 13:41
@oSumAtrIX oSumAtrIX changed the title Add patch to disable ads on cricbuzz app feat(Cricbuzz): Add Disable ads patch May 19, 2025
@LisoUseInAIKyrios LisoUseInAIKyrios changed the title feat(Cricbuzz): Add Disable ads patch feat(Cricbuzz): Add Hide ads patch May 19, 2025

@Suppress("unused")
val disableAdsPatch = bytecodePatch (
"Hide ads",
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
"Hide ads",
name = "Hide ads",

val disableAdsPatch = bytecodePatch (
"Hide ads",
) {
compatibleWith("com.cricbuzz.android" ("6.23.02"))
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
compatibleWith("com.cricbuzz.android" ("6.23.02"))
compatibleWith("com.cricbuzz.android"("6.23.02"))

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Everywhere else in the patches repo uses no space. If this is changed it should be changed everywhere.

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

But the suggestion is to remove the space, not add it


internal val userStateSwitchFingerprint = fingerprint {
strings("key.user.state", "NA")
opcodes(Opcode.SPARSE_SWITCH)
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Are the strings enough or is this Opcode needed?


execute {
userStateSwitchFingerprint.method.apply {
val opcodeIndex = indexOfFirstInstructionOrThrow(Opcode.MOVE_RESULT_OBJECT)
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Name these variables in a way that we know what these instructions do. For example:

  • What is this return we are moving-result-object to?
  • What is stored in the register we are getting?

Comment on lines +20 to +23
val insertIndex = opcodeIndex + 1

addInstructions(
insertIndex,
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
val insertIndex = opcodeIndex + 1
addInstructions(
insertIndex,
addInstruction(
opcodeIndex + 1,

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants
0