mirror of
https://github.com/revanced/revanced-integrations.git
synced 2025-01-17 07:17:31 +01:00
fix(twitter): correctly resolve to integrations methods
This commit is contained in:
parent
932e3356a1
commit
cd93917148
@ -1,5 +1,6 @@
|
|||||||
package app.revanced.twitter.patches.hook.json
|
package app.revanced.twitter.patches.hook.json
|
||||||
|
|
||||||
|
import app.revanced.twitter.patches.hook.patch.dummy.DummyHook
|
||||||
import app.revanced.twitter.utils.json.JsonUtils.parseJson
|
import app.revanced.twitter.utils.json.JsonUtils.parseJson
|
||||||
import app.revanced.twitter.utils.stream.StreamUtils
|
import app.revanced.twitter.utils.stream.StreamUtils
|
||||||
import org.json.JSONException
|
import org.json.JSONException
|
||||||
@ -7,8 +8,9 @@ import java.io.IOException
|
|||||||
import java.io.InputStream
|
import java.io.InputStream
|
||||||
|
|
||||||
object JsonHookPatch {
|
object JsonHookPatch {
|
||||||
|
// Additional hooks added by corresponding patch.
|
||||||
private val hooks = buildList<JsonHook> {
|
private val hooks = buildList<JsonHook> {
|
||||||
// Modified by corresponding patch.
|
add(DummyHook)
|
||||||
}
|
}
|
||||||
|
|
||||||
@JvmStatic
|
@JvmStatic
|
||||||
|
@ -0,0 +1,14 @@
|
|||||||
|
package app.revanced.twitter.patches.hook.patch.dummy
|
||||||
|
|
||||||
|
import app.revanced.twitter.patches.hook.json.BaseJsonHook
|
||||||
|
import app.revanced.twitter.patches.hook.json.JsonHookPatch
|
||||||
|
import org.json.JSONObject
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Dummy hook to reserve a register in [JsonHookPatch.hooks] list.
|
||||||
|
*/
|
||||||
|
object DummyHook : BaseJsonHook() {
|
||||||
|
override fun apply(json: JSONObject) {
|
||||||
|
// Do nothing.
|
||||||
|
}
|
||||||
|
}
|
Loading…
x
Reference in New Issue
Block a user