]> git.mjollnir.org Git - moodle.git/commitdiff
Now the "restore" option is showed to isteacheredit() teachers.
authorstronk7 <stronk7>
Sat, 16 Aug 2003 11:46:54 +0000 (11:46 +0000)
committerstronk7 <stronk7>
Sat, 16 Aug 2003 11:46:54 +0000 (11:46 +0000)
files/index.php

index 2f5ab4350a89999518ca5cd984ee02d837c46a81..95ce79940af6a6dc52b82de5e87fa38dafbafda8 100644 (file)
@@ -762,7 +762,7 @@ function displaydir ($wdir) {
             } else if ($icon == "zip.gif") {
                 $edittext = "<a href=\"index.php?id=$id&wdir=$wdir&file=$fileurl&action=unzip\">$strunzip</a>&nbsp;";
                 $edittext .= "<a href=\"index.php?id=$id&wdir=$wdir&file=$fileurl&action=listzip\">$strlist</a> ";
-                if (!empty($CFG->backup_version) and isteacher($id) and iscreator()) {
+                if (!empty($CFG->backup_version) and isteacher($id) and isteacheredit($id)) {
                     $edittext .= "<a href=\"index.php?id=$id&wdir=$wdir&file=$filesafe&action=restore\">$strrestore</a> ";
                 }
             } else {