Secret URL not working when page is submitted

Bug #1973479 reported by Robert Lyon
6
This bug affects 1 person
Affects Status Importance Assigned to Milestone
Mahara
21.10
Fix Released
High
Unassigned
22.04
Fix Released
High
Unassigned
22.10
Fix Released
High
Unassigned

Bug Description

Doing the following steps causes an error

1) Log in as admin
2) Create a group that allows submissions
3) Add normal user to group

4) Log in as normal user
5) Create a page and share it via a secret URL - copy link
6) Submit the page to the group
7) Log out

8) Visit the page via the secret URL

Get warning "[InvalidArgumentException]: group_user_access: user argument should be an integer"

Revision history for this message
Robert Lyon (robertl-9) wrote :

This works fine in 21.04 so only broken in 20.10+

Revision history for this message
Mahara Bot (dev-mahara) wrote : A patch has been submitted for review
Revision history for this message
Mahara Bot (dev-mahara) wrote : A change has been merged

Reviewed: https://reviews.mahara.org/c/mahara/+/12782
Committed: https://git.mahara.org/mahara/mahara/commit/445a967017ae11d84c4499af650fc8c720225f2a
Submitter: "Robert Lyon <email address hidden>"
Branch: main

commit 445a967017ae11d84c4499af650fc8c720225f2a
Author: Robert Lyon <email address hidden>
Date: Mon May 16 09:48:47 2022 +1200

Bug 1973479: Secret URLs not working when page submitted

Calling group_user_can_assess_submitted_views() when logged out throws
a warning so we need to check that we are logged in before calling
this function

Change-Id: Idd1034b2e0a86425e87069e3a78e2cb1f8b8207f
Signed-off-by: Robert Lyon <email address hidden>

Revision history for this message
Mahara Bot (dev-mahara) wrote : A patch has been submitted for review

Patch for "22.04_DEV" branch: https://reviews.mahara.org/c/mahara/+/13023

Revision history for this message
Mahara Bot (dev-mahara) wrote :

Patch for "21.10_DEV" branch: https://reviews.mahara.org/c/mahara/+/13024

Revision history for this message
Mahara Bot (dev-mahara) wrote : A change has been merged

Reviewed: https://reviews.mahara.org/c/mahara/+/13024
Committed: https://git.mahara.org/mahara/mahara/commit/70f1309198889cc45e4c6b1c46f30cdd07532ee7
Submitter: "Robert Lyon <email address hidden>"
Branch: 21.10_DEV

commit 70f1309198889cc45e4c6b1c46f30cdd07532ee7
Author: Robert Lyon <email address hidden>
Date: Mon May 16 09:48:47 2022 +1200

Bug 1973479: Secret URLs not working when page submitted

Calling group_user_can_assess_submitted_views() when logged out throws
a warning so we need to check that we are logged in before calling
this function

Change-Id: Idd1034b2e0a86425e87069e3a78e2cb1f8b8207f
Signed-off-by: Robert Lyon <email address hidden>
(cherry picked from commit 445a967017ae11d84c4499af650fc8c720225f2a)

Revision history for this message
Mahara Bot (dev-mahara) wrote :

Reviewed: https://reviews.mahara.org/c/mahara/+/13023
Committed: https://git.mahara.org/mahara/mahara/commit/c1c7c69f08fe0e7ab7838f0dfe2cbfe5149a23ae
Submitter: "Robert Lyon <email address hidden>"
Branch: 22.04_DEV

commit c1c7c69f08fe0e7ab7838f0dfe2cbfe5149a23ae
Author: Robert Lyon <email address hidden>
Date: Mon May 16 09:48:47 2022 +1200

Bug 1973479: Secret URLs not working when page submitted

Calling group_user_can_assess_submitted_views() when logged out throws
a warning so we need to check that we are logged in before calling
this function

Change-Id: Idd1034b2e0a86425e87069e3a78e2cb1f8b8207f
Signed-off-by: Robert Lyon <email address hidden>
(cherry picked from commit 445a967017ae11d84c4499af650fc8c720225f2a)

no longer affects: mahara
To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.