From e60598730d3d90ad5d5a93555a467ba7c2a5af14 Mon Sep 17 00:00:00 2001 From: Sam Hemelryk Date: Wed, 14 Nov 2012 13:34:54 +1300 Subject: [PATCH] MDL-36276 calendar: subscription events are no longer editable --- calendar/lib.php | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/calendar/lib.php b/calendar/lib.php index 698f40375b1ac..d815f82372884 100644 --- a/calendar/lib.php +++ b/calendar/lib.php @@ -1465,6 +1465,11 @@ function calendar_edit_event_allowed($event) { return false; } + // You cannot edit calendar subscription events presently. + if (!empty($event->subscriptionid)) { + return false; + } + $sitecontext = context_system::instance(); // if user has manageentries at site level, return true if (has_capability('moodle/calendar:manageentries', $sitecontext)) {