mirror of
https://github.com/ReVanced/revanced-patcher.git
synced 2024-11-10 09:08:04 +01:00
fix: show error message instead of null
This commit is contained in:
parent
9a4d30e152
commit
8d95b14f35
1 changed files with 3 additions and 1 deletions
|
@ -274,7 +274,9 @@ class Patcher(private val options: PatcherOptions) {
|
|||
val result = applyPatch(dependency, appliedPatches)
|
||||
if (result.isSuccess()) return@forEach
|
||||
|
||||
val errorMessage = result.error()!!.cause
|
||||
val error = result.error()!!
|
||||
val errorMessage = error.cause ?: error.message
|
||||
|
||||
return PatchResultError("'$patchName' depends on '${dependency.patchName}' but the following error was raised: $errorMessage")
|
||||
}
|
||||
|
||||
|
|
Loading…
Reference in a new issue