aboutsummaryrefslogtreecommitdiff
path: root/app/controllers/course/statusgroups.php
diff options
context:
space:
mode:
authorElmar Ludwig <elmar.ludwig@uni-osnabrueck.de>2021-11-15 15:33:49 +0100
committerElmar Ludwig <elmar.ludwig@uni-osnabrueck.de>2021-11-15 15:33:49 +0100
commita0470bbb814d7fe10ddf1744f258b92194643de3 (patch)
tree638ab313bbdfae788dbf9538d861dff31d9e1cb3 /app/controllers/course/statusgroups.php
parent9f1b7ce46ea52e13c39241ec0e9b49c9803a93ac (diff)
allow unsetting group folder option, fixes #422
Diffstat (limited to 'app/controllers/course/statusgroups.php')
-rw-r--r--app/controllers/course/statusgroups.php5
1 files changed, 2 insertions, 3 deletions
diff --git a/app/controllers/course/statusgroups.php b/app/controllers/course/statusgroups.php
index eae298c..79c595b 100644
--- a/app/controllers/course/statusgroups.php
+++ b/app/controllers/course/statusgroups.php
@@ -518,8 +518,7 @@ class Course_StatusgroupsController extends AuthenticatedController
$endtime = 0;
}
}
- $statusgruppe = new Statusgruppen($group_id);
- $position = $statusgruppe->position;
+ $position = Statusgruppen::find($group_id)->position;
$group = Statusgruppen::createOrUpdate(
$group_id,
Request::get('name'),
@@ -528,7 +527,7 @@ class Course_StatusgroupsController extends AuthenticatedController
Request::int('selfassign', 0) + Request::int('exclusive', 0),
strtotime(Request::get('selfassign_start', 'now')),
Request::get('selfassign_end') ? strtotime(Request::get('selfassign_end')) : 0,
- Request::int('makefolder', 0) || $statusgruppe->hasFolder(),
+ Request::int('makefolder', 0),
Request::getArray('dates')
);