← Back to team overview

mahara-contributors team mailing list archive

[Bug 1251089] A change has been merged

 

Reviewed:  https://reviews.mahara.org/2893
Committed: http://gitorious.org/mahara/mahara/commit/9d491d4afedf5385f14dc0b9bcbc98daa5e985f8
Submitter: Son Nguyen (son.nguyen@xxxxxxxxxxxxxxx)
Branch:    master

commit 9d491d4afedf5385f14dc0b9bcbc98daa5e985f8
Author: Robert Lyon <robertl@xxxxxxxxxxxxxxx>
Date:   Thu Jan 9 12:44:24 2014 +1300

Correcting licensedefault's default value for 'no institution'

Bug #1251089

Change-Id: Ib7cff43da8c37c383985e0a5b254280aba138bd5
Signed-off-by: Robert Lyon <robertl@xxxxxxxxxxxxxxx>

-- 
You received this bug notification because you are a member of Mahara
Contributors, which is subscribed to Mahara.
Matching subscriptions: Subscription for all Mahara Contributors -- please ask on #mahara-dev or mahara.org forum before editing or unsubscribing it!
https://bugs.launchpad.net/bugs/1251089

Title:
  Invalid value for licensedefault

Status in Mahara ePortfolio:
  Fix Committed

Bug description:
  If I have a site and enable the 'General' setting: License metadata
  and then masquerade as different user and then go to their account
  settings  page I get the below error (see first error).

  From what I can see in general_account_prefs_form_elements($prefs)
  there is a bit of code to set the institution's default as the default
  for the form.

  But 'no institution' doesn't set the default license as it's edit form
  does not display this option and on save you get errors (shown below).

  The 'no institution' institution needs to be able to handle this like
  any other institution - or be exempt from needing it.


  [WAR] 99 (lib/pieforms/pieform.php:1236) Invalid value for select "licensedefault"
  Call stack (most recent first):

      log_message("Invalid value for select "licensedefault"", 8, true, true, "/home/robertl/htdocs/mahara-testing/mahara/htdocs/...", 1236) at /home/robertl/htdocs/mahara-testing/mahara/htdocs/lib/errors.php:430
      error(1024, "Invalid value for select "licensedefault"", "/home/robertl/htdocs/mahara-testing/mahara/htdocs/...", 1236, array(size 2)) at Unknown:0
      trigger_error("Invalid value for select "licensedefault"", 1024) at /home/robertl/htdocs/mahara-testing/mahara/htdocs/lib/pieforms/pieform.php:1236
      Pieform::info("Invalid value for select "licensedefault"") at /home/robertl/htdocs/mahara-testing/mahara/htdocs/lib/pieforms/pieform/elements/select.php:102
      pieform_element_select(object(Pieform), array(size 12)) at /home/robertl/htdocs/mahara-testing/mahara/htdocs/lib/pieforms/pieform.php:1402
      Pieform->build_element_html(array(size 12)) at /home/robertl/htdocs/mahara-testing/mahara/htdocs/lib/pieforms/pieform.php:673
      Pieform->build() at /home/robertl/htdocs/mahara-testing/mahara/htdocs/lib/pieforms/pieform.php:171
      Pieform::process(array(size 8)) at /home/robertl/htdocs/mahara-testing/mahara/htdocs/lib/pieforms/pieform.php:71
      pieform(array(size 8)) at /home/robertl/htdocs/mahara-testing/mahara/htdocs/account/index.php:266

  --------------------------------------------------------------------------------------------------------------------------------------------------------------------------

  [WAR] 11 (admin/users/institutions.php:585) Undefined index: licensemandatory
  Call stack (most recent first):

      log_message("Undefined index: licensemandatory", 8, true, true, "/home/robertl/htdocs/mahara-testing/mahara/htdocs/...", 585) at /home/robertl/htdocs/mahara-testing/mahara/htdocs/lib/errors.php:430
      error(8, "Undefined index: licensemandatory", "/home/robertl/htdocs/mahara-testing/mahara/htdocs/...", 585, array(size 3)) at /home/robertl/htdocs/mahara-testing/mahara/htdocs/admin/users/institutions.php:585
      institution_validate(object(Pieform), array(size 34)) at Unknown:0
      call_user_func_array("institution_validate", array(size 2)) at /home/robertl/htdocs/mahara-testing/mahara/htdocs/lib/pieforms/pieform.php:1348
      Pieform->validate(array(size 34)) at /home/robertl/htdocs/mahara-testing/mahara/htdocs/lib/pieforms/pieform.php:506
      Pieform->__construct(array(size 5)) at /home/robertl/htdocs/mahara-testing/mahara/htdocs/lib/pieforms/pieform.php:170
      Pieform::process(array(size 5)) at /home/robertl/htdocs/mahara-testing/mahara/htdocs/lib/pieforms/pieform.php:71
      pieform(array(size 5)) at /home/robertl/htdocs/mahara-testing/mahara/htdocs/admin/users/institutions.php:517

  [WAR] 11 (admin/users/institutions.php:677) Undefined index: licensemandatory
  Call stack (most recent first):

      log_message("Undefined index: licensemandatory", 8, true, true, "/home/robertl/htdocs/mahara-testing/mahara/htdocs/...", 677) at /home/robertl/htdocs/mahara-testing/mahara/htdocs/lib/errors.php:430
      error(8, "Undefined index: licensemandatory", "/home/robertl/htdocs/mahara-testing/mahara/htdocs/...", 677, array(size 11)) at /home/robertl/htdocs/mahara-testing/mahara/htdocs/admin/users/institutions.php:677
      institution_submit(object(Pieform), array(size 34)) at Unknown:0
      call_user_func_array("institution_submit", array(size 2)) at /home/robertl/htdocs/mahara-testing/mahara/htdocs/lib/pieforms/pieform.php:528
      Pieform->__construct(array(size 5)) at /home/robertl/htdocs/mahara-testing/mahara/htdocs/lib/pieforms/pieform.php:170
      Pieform::process(array(size 5)) at /home/robertl/htdocs/mahara-testing/mahara/htdocs/lib/pieforms/pieform.php:71
      pieform(array(size 5)) at /home/robertl/htdocs/mahara-testing/mahara/htdocs/admin/users/institutions.php:517

  [WAR] 11 (admin/users/institutions.php:678) Undefined index: licensedefault
  Call stack (most recent first):

      log_message("Undefined index: licensedefault", 8, true, true, "/home/robertl/htdocs/mahara-testing/mahara/htdocs/...", 678) at /home/robertl/htdocs/mahara-testing/mahara/htdocs/lib/errors.php:430
      error(8, "Undefined index: licensedefault", "/home/robertl/htdocs/mahara-testing/mahara/htdocs/...", 678, array(size 11)) at /home/robertl/htdocs/mahara-testing/mahara/htdocs/admin/users/institutions.php:678
      institution_submit(object(Pieform), array(size 34)) at Unknown:0
      call_user_func_array("institution_submit", array(size 2)) at /home/robertl/htdocs/mahara-testing/mahara/htdocs/lib/pieforms/pieform.php:528
      Pieform->__construct(array(size 5)) at /home/robertl/htdocs/mahara-testing/mahara/htdocs/lib/pieforms/pieform.php:170
      Pieform::process(array(size 5)) at /home/robertl/htdocs/mahara-testing/mahara/htdocs/lib/pieforms/pieform.php:71
      pieform(array(size 5)) at /home/robertl/htdocs/mahara-testing/mahara/htdocs/admin/users/institutions.php:517

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


References