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-37539-23' of github.com:damyon/moodle into MOODLE_2…

…3_STABLE
  • Loading branch information...
commit 19740fe4a6dd74f528579e19a595e119a292efb3 2 parents 4e3f4bd + 508f42e
Eloy Lafuente (stronk7) stronk7 authored

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

  1. +6 1 mod/assign/submission/comments/locallib.php
7 mod/assign/submission/comments/locallib.php
@@ -113,7 +113,12 @@ public function can_upgrade($type, $version) {
113 113 * @return bool was it a success? (false will trigger a rollback)
114 114 */
115 115 public function upgrade_settings(context $oldcontext, stdClass $oldassignment, & $log) {
116   - // first upgrade settings (nothing to do)
  116 + if ($oldassignment->assignmenttype == 'upload') {
  117 + // Disable if allow notes was not enabled.
  118 + if (!$oldassignment->var2) {
  119 + $this->disable();
  120 + }
  121 + }
117 122 return true;
118 123 }
119 124

0 comments on commit 19740fe

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