From 91aa019f8d3d87fbf7affeb7abc2b02ba87af5c3 Mon Sep 17 00:00:00 2001 From: Lucaskyy Date: Tue, 22 Mar 2022 22:22:46 +0100 Subject: [PATCH] feat: use supplier instead of KClass BREAKING CHANGE: signature of patches was changed --- src/main/kotlin/app/revanced/patches/Index.kt | 9 ++++----- 1 file changed, 4 insertions(+), 5 deletions(-) diff --git a/src/main/kotlin/app/revanced/patches/Index.kt b/src/main/kotlin/app/revanced/patches/Index.kt index 53c603ce..76042262 100644 --- a/src/main/kotlin/app/revanced/patches/Index.kt +++ b/src/main/kotlin/app/revanced/patches/Index.kt @@ -4,7 +4,6 @@ import app.revanced.patcher.patch.Patch import app.revanced.patches.ads.VideoAds import app.revanced.patches.layouts.CreateButtonRemover import app.revanced.patches.layouts.MinimizedPlayback -import kotlin.reflect.KClass /** * Index contains all the patches and should be imported when using this library. @@ -15,9 +14,9 @@ object Index { * Array of patches. * New patches should be added to the array. */ - val patches: Array> = arrayOf( - VideoAds::class, - MinimizedPlayback::class, - CreateButtonRemover::class + val patches: Array<() -> Patch> = arrayOf( + ::VideoAds, + ::MinimizedPlayback, + ::CreateButtonRemover ) } \ No newline at end of file