-
Notifications
You must be signed in to change notification settings - Fork 5
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Exception thrown in Totara - Videotime view.php #77
Comments
Hi @pf-aleido, thanks for reporting this issue. On my totara 18 test site, I cannot reproduce the issue with the current version of Video time for totara (1.8). Can you please check if you still encounter the issue with video time 1.8? Thanks! |
@stefanscholz Hi Stefan, Can you reproduce the bug in lower versions of mod_videotime in your Totara? Heres a screenshot showing debugging trace of the exception, in a totara 18.9 with mod_videotime 1.7.2 |
I now tried with mod_videotime branch totara18 Same exception with that version. |
Hi @pf-aleido, I don't have multiple test sites for totara 18 available at the moment, so cannot test it with a lower version of video time unfortunately. As you know, it is not possible to downgrade plugins on totara, and I need the test site for testing purposes for the 1.8 version (I already have setup multiple test scenarios) So just to clarify: the issue that you encounter is that if an authenticated user that is not enrolled in a course gets an error if he tries to navigate to a video time activity via direct url? For my understanding; why is this happening? I mean, why would users actually do that? Is the link somewhere available to the learner (maybe in a different course) and you'd want the enrolment page to show? Please explain. |
One more thing: are there any specific reasons why you are still using 1.7? |
We are not sure about the customers intention actually. Its not a frequent problem. But some users got them from somewhere. Might be that learners share links to each other, or the customer publish direct links in external systems. |
Theres no specific reason why we still use 1.7 except from lack of resources :). |
We use mod_videotime release 1.5.5 in a Totara v13
Same exception in mod_videotime release 1.7.2 in a Totara v18
An exception are throwned when a non-enrolled user visit the activity view page.
Reproduce:
In Totara, enable audiencevisibility
Create a course, add a videotime activity.
Copy the url to the videotime activity view page
Log in as a non enrolled user. Go directly to the activity view page with the url copied in previous step.
An exception are throwned - related to the $PAGE object.
Proposed solution:
On mod_videotime/view.php, setup $PAGE more like server/mod/facetoface/view.php
Set $PAGE->set_cm($cm)
Before call to require_login:
$PAGE->set_url('/mod/videotime/view.php', ['id' => $cm->id]);
$PAGE->set_cm($cm);
The text was updated successfully, but these errors were encountered: