]> git.mjollnir.org Git - moodle.git/commitdiff
MDL-15712 fixed groups regressions - credit goes to Daniel Servos
authorskodak <skodak>
Sat, 19 Jul 2008 08:07:51 +0000 (08:07 +0000)
committerskodak <skodak>
Sat, 19 Jul 2008 08:07:51 +0000 (08:07 +0000)
lib/grouplib.php

index 7b3d6db12e276b2f5d4831eef08c1caf09f5c1a2..a4eb2b1c9e5ff9bec2154669a9ac99ef58a3e80e 100644 (file)
@@ -544,7 +544,7 @@ function groups_get_course_group($course, $update=false) {
     }
 
     // init activegroup array
-    if (!array_key_exists('activegroup', $SESSION)) {
+    if (!isset($SESSION->activegroup)) {
         $SESSION->activegroup = array();
     }
     if (!array_key_exists($course->id, $SESSION->activegroup)) {
@@ -620,7 +620,7 @@ function groups_get_activity_group($cm, $update=false) {
     }
 
     // init activegroup array
-    if (!array_key_exists('activegroup', $SESSION)) {
+    if (!isset($SESSION->activegroup)) {
         $SESSION->activegroup = array();
     }
     if (!array_key_exists($cm->course, $SESSION->activegroup)) {