]> git.mjollnir.org Git - moodle.git/commitdiff
MDL-14978 removed obsoleted iscreator()
authorskodak <skodak>
Sun, 25 May 2008 11:02:58 +0000 (11:02 +0000)
committerskodak <skodak>
Sun, 25 May 2008 11:02:58 +0000 (11:02 +0000)
lib/deprecatedlib.php

index 5f50f3235c67da2b38b3cae828beca3c80b99fef..391c6ec038cb719a1788f6abec456e2aef6919f3 100644 (file)
@@ -119,25 +119,6 @@ function isteacherinanycourse($userid=0, $includeadmin=true) {
     return false;
 }
 
-/**
- * Determines if a user can create new courses
- *
- * @param int $userid The user being tested. You can set this to 0 or leave it blank to test the currently logged in user.
- * @return bool
- */
-function iscreator ($userid=0) {
-    global $CFG;
-
-    if (empty($CFG->rolesactive)) {
-        return false;
-    }
-
-    $context = get_context_instance(CONTEXT_SYSTEM);
-
-    return (has_capability('moodle/legacy:coursecreator', $context, $userid, false)
-         or has_capability('moodle/legacy:admin', $context, $userid, false));
-}
-
 
 /**
  * Determines if the specified user is logged in as guest.