aboutsummaryrefslogtreecommitdiff
path: root/app/controllers/calendar/calendar.php
diff options
context:
space:
mode:
authorMoritz Strohm <strohm@data-quest.de>2024-03-21 15:17:56 +0000
committerPeter Thienel <thienel@data-quest.de>2024-03-21 15:17:56 +0000
commit0dfa6387519755371359e36cae55526f43217f2d (patch)
tree39d81a5c8ab2bdf940e3a6628d5657038533a1c3 /app/controllers/calendar/calendar.php
parenteed21fa552f33483dc110f730507283f2a4a03e2 (diff)
default to current user calendar if no calendar is selected, fixes #3874
Closes #3874 Merge request studip/studip!2725
Diffstat (limited to 'app/controllers/calendar/calendar.php')
-rw-r--r--app/controllers/calendar/calendar.php4
1 files changed, 4 insertions, 0 deletions
diff --git a/app/controllers/calendar/calendar.php b/app/controllers/calendar/calendar.php
index 33c4113..6ae77eb 100644
--- a/app/controllers/calendar/calendar.php
+++ b/app/controllers/calendar/calendar.php
@@ -141,6 +141,10 @@ class Calendar_CalendarController extends AuthenticatedController
} elseif ($user_id) {
$calendar_owner = User::getCalendarOwner($user_id);
$view = 'single';
+ } else {
+ //Show the calendar of the current user.
+ $view = 'single';
+ $calendar_owner = User::findCurrent();
}
} else {
//Show the calendar of the current user.