← Back to team overview

mahara-contributors team mailing list archive

[Bug 1023834] Re: Refactor login form elements code duplication

 

** Changed in: mahara
    Milestone: 1.6.0 => 1.7.0

** Changed in: mahara
       Status: Triaged => Fix Committed

-- 
You received this bug notification because you are a member of Mahara
Contributors, which is subscribed to Mahara.
https://bugs.launchpad.net/bugs/1023834

Title:
  Refactor login form elements code duplication

Status in Mahara ePortfolio:
  Fix Committed

Bug description:
  All login form elements along with extra login form elements are
  declared twice, in auth_get_login_form() and
  auth_generate_login_form() respectively. The differences are really
  minor, so I suggest to move login form elements generation to separate
  function, making it less prone to errors.

  auth_get_login_form() - used when logged-off user tries to access something different from main page or session has expired. 
  auth_generate_login_form()  - used in side-block on the main page

  The auth_get_login_form() version of login form is missing (see
  attached diff):

  * 'defaultvalue' is missing in  'login_username'  - can be used, nothing major
  * 'login_password' is not regarded as 'required' field here for some reason...
  * Register link is not shown - I do not see a reason why it should not be displayed
  * Login container is missing 'login' class - can be added, does not break styles

To manage notifications about this bug go to:
https://bugs.launchpad.net/mahara/+bug/1023834/+subscriptions


References