diff options
Diffstat (limited to 'server/src/com/vaadin/Application.java')
-rw-r--r-- | server/src/com/vaadin/Application.java | 19 |
1 files changed, 19 insertions, 0 deletions
diff --git a/server/src/com/vaadin/Application.java b/server/src/com/vaadin/Application.java index 2af3c6a59f..f368257ecd 100644 --- a/server/src/com/vaadin/Application.java +++ b/server/src/com/vaadin/Application.java @@ -239,6 +239,25 @@ public class Application implements Terminal.ErrorListener, Serializable { * This implementation simulates the way of finding a window for a * request by extracting a window name from the requested path and * passes that name to {@link #getWindow(String)}. + * <p> + * {@inheritDoc} + */ + @Override + public UI getUIForRequest(WrappedRequest request) { + UI uiInstance = getUIInstance(request); + if (uiInstance.getUIId() == -1) { + // Not initialized -> Let go through createUIInstance to make it + // initialized + return null; + } else { + return uiInstance; + } + } + + /** + * This implementation simulates the way of finding a window for a + * request by extracting a window name from the requested path and + * passes that name to {@link #getWindow(String)}. * * <p> * {@inheritDoc} |