mirror of
https://github.com/moodle/moodle.git
synced 2025-08-04 00:16:46 +02:00
MDL-14589 fixed error message if url malformed
This commit is contained in:
parent
b0ea27b441
commit
4937508878
1 changed files with 3 additions and 1 deletions
|
@ -50,7 +50,9 @@ if (count($args) == 0) { // always at least user id
|
||||||
$contextid = (int)array_shift($args);
|
$contextid = (int)array_shift($args);
|
||||||
$filearea = array_shift($args);
|
$filearea = array_shift($args);
|
||||||
|
|
||||||
$context = get_context_instance_by_id($contextid);
|
if (!$context = get_context_instance_by_id($contextid)) {
|
||||||
|
send_file_not_found();
|
||||||
|
}
|
||||||
$fs = get_file_storage();
|
$fs = get_file_storage();
|
||||||
|
|
||||||
|
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue