mirror of
https://github.com/mamoe/mirai.git
synced 2025-03-13 06:30:13 +08:00
[console] Fixed reaching UNREACHABLE_CLAUSE when running extensions with non-null function results. (#2528)
This commit is contained in:
parent
48d674b383
commit
a6afd9540c
@ -147,8 +147,8 @@ public inline fun <T, R> InterceptResult<T>.fold(
|
||||
callsInPlace(onIntercepted, InvocationKind.AT_MOST_ONCE)
|
||||
callsInPlace(otherwise, InvocationKind.AT_MOST_ONCE)
|
||||
}
|
||||
value?.let(otherwise)
|
||||
reason?.let(onIntercepted)
|
||||
value?.let { return otherwise(it) }
|
||||
reason?.let { return onIntercepted(it) }
|
||||
UNREACHABLE_CLAUSE
|
||||
}
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user