Updated Branches:
  refs/heads/master e1a481616 -> 69398a064

WICKET-5490 AuthenticatedWebApplication#onUnauthorizedPage() should work with 
Component, not Page


Project: http://git-wip-us.apache.org/repos/asf/wicket/repo
Commit: http://git-wip-us.apache.org/repos/asf/wicket/commit/69398a06
Tree: http://git-wip-us.apache.org/repos/asf/wicket/tree/69398a06
Diff: http://git-wip-us.apache.org/repos/asf/wicket/diff/69398a06

Branch: refs/heads/master
Commit: 69398a064a74f59898a4b6e00d3bfc5482c7268b
Parents: e1a4816
Author: Martin Tzvetanov Grigorov <[email protected]>
Authored: Tue Jan 28 11:26:18 2014 +0100
Committer: Martin Tzvetanov Grigorov <[email protected]>
Committed: Tue Jan 28 11:26:18 2014 +0100

----------------------------------------------------------------------
 .../authroles/authentication/AuthenticatedWebApplication.java | 7 +++----
 1 file changed, 3 insertions(+), 4 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/wicket/blob/69398a06/wicket-auth-roles/src/main/java/org/apache/wicket/authroles/authentication/AuthenticatedWebApplication.java
----------------------------------------------------------------------
diff --git 
a/wicket-auth-roles/src/main/java/org/apache/wicket/authroles/authentication/AuthenticatedWebApplication.java
 
b/wicket-auth-roles/src/main/java/org/apache/wicket/authroles/authentication/AuthenticatedWebApplication.java
index 3d668f3..a95e5b2 100644
--- 
a/wicket-auth-roles/src/main/java/org/apache/wicket/authroles/authentication/AuthenticatedWebApplication.java
+++ 
b/wicket-auth-roles/src/main/java/org/apache/wicket/authroles/authentication/AuthenticatedWebApplication.java
@@ -97,7 +97,7 @@ public abstract class AuthenticatedWebApplication extends 
WebApplication
                        }
                        else
                        {
-                               onUnauthorizedPage((Page)component);
+                               onUnauthorizedPage(component);
                        }
                }
                else
@@ -153,11 +153,10 @@ public abstract class AuthenticatedWebApplication extends 
WebApplication
         * application's home page.
         * 
         * @param page
-        *            The page
+        *            The partially constructed page (only the component id is 
guaranteed to be valid).
         */
-       protected void onUnauthorizedPage(final Page page)
+       protected void onUnauthorizedPage(final Component page)
        {
-               // The component was not a page, so throw an exception
                throw new UnauthorizedInstantiationException(page.getClass());
        }
 }

Reply via email to