← Back to team overview

mahara-contributors team mailing list archive

[Bug 1367939] Re: Error on registration if confirmed registration is turned on and copy collection in play

 

Did you also check the 'Copy for new users' option when on step for
'Check Allow copying'?

The error is when it tries to copy the collection pages to the new user
on user creation.

-- 
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/1367939

Title:
  Error on registration if confirmed registration is turned on and copy
  collection in play

Status in Mahara ePortfolio:
  Fix Committed
Status in Mahara 1.7 series:
  In Progress
Status in Mahara 1.8 series:
  In Progress
Status in Mahara 1.9 series:
  Fix Committed

Bug description:
  If you have an institution with:
  - both "Registration allowed" and "Confirm registration" chosen in it's config.
  - a collection that has the  "Copy for new institution members" checked  (under Admin -> Institution -> Share -> [name of collection] -> Advanced options)

  When a new user registers the admin gets an email to approve them, and
  on approval, the new user gets an email to complete signup.

  When the user clicks the complete signup link we get an error like:

  [WAR] 5f (lib/view.php:503) View::_create: User 0 is not allowed to create a view for owner 13
  Call stack (most recent first):

      View::_create(array(size 5), 0) at /home/robertl/htdocs/mahara-devel/mahara/htdocs/lib/view.php:371
      View::create_from_template(array(size 5), "18", 0, false, true) at /home/robertl/htdocs/mahara-devel/mahara/htdocs/lib/collection.php:274
      Collection::create_from_template(array(size 1), "2", null, false, true) at /home/robertl/htdocs/mahara-devel/mahara/htdocs/auth/user.php:1302
      User->copy_institution_views_collections_to_new_member("squid") at /home/robertl/htdocs/mahara-devel/mahara/htdocs/lib/institution.php:338
      Institution->addUserAsMember(object(User)) at /home/robertl/htdocs/mahara-devel/mahara/htdocs/auth/user.php:683
      User->join_institution("squid") at /home/robertl/htdocs/mahara-devel/mahara/htdocs/register.php:150
      create_registered_user() at /home/robertl/htdocs/mahara-devel/mahara/htdocs/register.php:198

  The problem being the system doesn't 'know' who is the authority user
  giving permission for this new user to copy the collection and so
  tries to do it with guest user (userid = 0).

  We need to have a way of either working out who the authority user id
  would be - or ignore it in this particular case (if safe to do)

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


References