Arthur Bogaart pushed to branch bugfix/CMS-10071 at cms-community / hippo-cms


Commits:
912c02ff by Arthur Bogaart at 2016-04-29T11:12:18+02:00
CMS-10071 Expose cookie methods to subclasses of LoginPanel

- - - - -


1 changed file:

- engine/src/main/java/org/hippoecm/frontend/plugins/login/LoginPanel.java


Changes:

=====================================
engine/src/main/java/org/hippoecm/frontend/plugins/login/LoginPanel.java
=====================================
--- a/engine/src/main/java/org/hippoecm/frontend/plugins/login/LoginPanel.java
+++ b/engine/src/main/java/org/hippoecm/frontend/plugins/login/LoginPanel.java
@@ -1,5 +1,5 @@
 /*
- *  Copyright 2015 Hippo B.V. (http://www.onehippo.com)
+ *  Copyright 2015-2016 Hippo B.V. (http://www.onehippo.com)
  *
  *  Licensed under the Apache License, Version 2.0 (the "License");
  *  you may not use this file except in compliance with the License.
@@ -42,7 +42,6 @@ import org.apache.wicket.markup.html.form.PasswordTextField;
 import org.apache.wicket.markup.html.form.RequiredTextField;
 import org.apache.wicket.markup.html.panel.FeedbackPanel;
 import org.apache.wicket.markup.html.panel.Panel;
-import org.apache.wicket.model.Model;
 import org.apache.wicket.model.PropertyModel;
 import org.apache.wicket.model.ResourceModel;
 import org.apache.wicket.request.resource.JavaScriptResourceReference;
@@ -244,13 +243,13 @@ public class LoginPanel extends Panel {
         }
     }
 
-    private void setCookieValue(final String cookieName, final String 
cookieValue, final int maxAge) {
+    protected void setCookieValue(final String cookieName, final String 
cookieValue, final int maxAge) {
         Cookie localeCookie = new Cookie(cookieName, cookieValue);
         localeCookie.setMaxAge(maxAge);
         WebApplicationHelper.retrieveWebResponse().addCookie(localeCookie);
     }
 
-    private String getCookieValue(final String cookieName) {
+    protected String getCookieValue(final String cookieName) {
         Cookie[] cookies = 
WebApplicationHelper.retrieveWebRequest().getContainerRequest().getCookies();
         if (cookies != null) {
             for (Cookie cookie : cookies) {



View it on GitLab: 
https://code.onehippo.org/cms-community/hippo-cms/commit/912c02fffd36280d7c97f64e24f6f2d78f5489fd
_______________________________________________
Hippocms-svn mailing list
Hippocms-svn@lists.onehippo.org
https://lists.onehippo.org/mailman/listinfo/hippocms-svn

Reply via email to