Skip to content
This repository

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP
Browse code

Merge branch 'MDL-37797_m24' of git://github.com/rwijaya/moodle into …

…MOODLE_24_STABLE
  • Loading branch information...
commit 8b2034bc7b82033c2abcdad5e38443c40d35c846 2 parents dc85a9e + 3bcf80e
Dan Poltawski danpoltawski authored

Showing 1 changed file with 1 addition and 1 deletion. Show diff stats Hide diff stats

  1. +1 1  lib/filelib.php
2  lib/filelib.php
@@ -4277,7 +4277,7 @@ function file_pluginfile($relativepath, $forcedownload, $preview = null) {
4277 4277 send_file_not_found();
4278 4278 }
4279 4279
4280   - $bprecord = $DB->get_record('block_positions', array('blockinstanceid' => $context->instanceid), 'visible');
  4280 + $bprecord = $DB->get_record('block_positions', array('contextid' => $context->id, 'blockinstanceid' => $context->instanceid));
4281 4281 // User can't access file, if block is hidden or doesn't have block:view capability
4282 4282 if (($bprecord && !$bprecord->visible) || !has_capability('moodle/block:view', $context)) {
4283 4283 send_file_not_found();

0 comments on commit 8b2034b

Please sign in to comment.
Something went wrong with that request. Please try again.