From cae18d7ec0ab1a73d8df6f1813d61f327943b127 Mon Sep 17 00:00:00 2001 From: Jeremy Grelle Date: Wed, 5 Mar 2008 14:30:18 +0000 Subject: [PATCH] Cleanup - RequestContext null check so that it works in standard JSF requests --- .../expression/el/ImplicitFlowVariableELResolver.java | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/spring-webflow/src/main/java/org/springframework/webflow/expression/el/ImplicitFlowVariableELResolver.java b/spring-webflow/src/main/java/org/springframework/webflow/expression/el/ImplicitFlowVariableELResolver.java index d6a08cb8..5437cf0e 100644 --- a/spring-webflow/src/main/java/org/springframework/webflow/expression/el/ImplicitFlowVariableELResolver.java +++ b/spring-webflow/src/main/java/org/springframework/webflow/expression/el/ImplicitFlowVariableELResolver.java @@ -27,6 +27,9 @@ public class ImplicitFlowVariableELResolver extends ELResolver { return null; } RequestContext requestContext = RequestContextHolder.getRequestContext(); + if (requestContext == null) { + return null; + } if (ImplicitVariables.matches(property)) { context.setPropertyResolved(true); return ImplicitVariables.value(context, requestContext, property).getClass(); @@ -40,6 +43,9 @@ public class ImplicitFlowVariableELResolver extends ELResolver { return null; } RequestContext requestContext = RequestContextHolder.getRequestContext(); + if (requestContext == null) { + return null; + } if (ImplicitVariables.matches(property)) { context.setPropertyResolved(true); return ImplicitVariables.value(context, requestContext, property);