mirror of
https://github.com/revanced/revanced-patcher.git
synced 2025-04-30 05:14:26 +02:00
fix: Catch correct exception
This commit is contained in:
parent
9a109c129b
commit
637d48746f
@ -65,7 +65,7 @@ sealed class PatchBundleLoader private constructor(
|
|||||||
internal fun Class<*>.getInstance(logger: Logger): Patch<*>? {
|
internal fun Class<*>.getInstance(logger: Logger): Patch<*>? {
|
||||||
return try {
|
return try {
|
||||||
getField("INSTANCE").get(null)
|
getField("INSTANCE").get(null)
|
||||||
} catch (exception: NoSuchFileException) {
|
} catch (exception: NoSuchFieldException) {
|
||||||
logger.fine(
|
logger.fine(
|
||||||
"Patch class '${name}' has no INSTANCE field, therefor not a singleton. " +
|
"Patch class '${name}' has no INSTANCE field, therefor not a singleton. " +
|
||||||
"Will try to instantiate it."
|
"Will try to instantiate it."
|
||||||
|
Loading…
x
Reference in New Issue
Block a user