MDL-45729 assign: Fix for assign unit tests

Check the user in the params, not the $USER
This commit is contained in:
Damyon Wiese 2014-06-10 11:39:20 +08:00
parent 3150271c22
commit 5ba4ca894a

View File

@ -3731,7 +3731,7 @@ class assign {
$gradingcontrollerpreview,
$instance->attemptreopenmethod,
$instance->maxattempts);
if (has_capability('mod/assign:submit', $this->get_context())) {
if (has_capability('mod/assign:submit', $this->get_context(), $user)) {
$o .= $this->get_renderer()->render($submissionstatus);
}