From ea4588be44afa53cdff2908edcff6ab93adbd6cd Mon Sep 17 00:00:00 2001 From: Danila Fedorin Date: Sat, 23 Sep 2017 15:43:07 -0700 Subject: [PATCH] Add more descriptive message to context exceptions. --- .../main/kotlin/org/nwapw/abacus/context/ChainSearchDelegate.kt | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/core/src/main/kotlin/org/nwapw/abacus/context/ChainSearchDelegate.kt b/core/src/main/kotlin/org/nwapw/abacus/context/ChainSearchDelegate.kt index 64d933a..7f4e21a 100644 --- a/core/src/main/kotlin/org/nwapw/abacus/context/ChainSearchDelegate.kt +++ b/core/src/main/kotlin/org/nwapw/abacus/context/ChainSearchDelegate.kt @@ -24,7 +24,7 @@ class ChainSearchDelegate(private val valueGetter: EvaluationContext.() - currentRef = currentRef.parent ?: break returnedValue = currentRef.valueGetter() } - return returnedValue ?: throw ContextException() + return returnedValue ?: throw ContextException("context chain does not contain value") } } \ No newline at end of file