Merging from HEAD:
Fix for bug 4203: When adding recurring events, if the event title contained an apostrophe then only the first event of the series would get created. Tricky bad interaction with add_to_log, the reporter for this should get a prize. ;-)
This commit is contained in:
+3
-4
@@ -211,8 +211,7 @@
|
||||
$eventid = insert_record('event', $form, true);
|
||||
|
||||
/// Log the event entry.
|
||||
$form->name = stripslashes($form->name); //To avoid double-slashes
|
||||
add_to_log($form->courseid, 'calendar', 'add', 'event.php?action=edit&id='.$eventid, $form->name);
|
||||
add_to_log($form->courseid, 'calendar', 'add', 'event.php?action=edit&id='.$eventid, stripslashes($form->name));
|
||||
|
||||
if ($form->repeat) {
|
||||
for($i = 1; $i < $form->repeats; $i++) {
|
||||
@@ -226,9 +225,9 @@
|
||||
|
||||
/// Get the event id for the log record.
|
||||
$eventid = insert_record('event', $form, true);
|
||||
|
||||
/// Log the event entry.
|
||||
$form->name = stripslashes($form->name); //To avoid double-slashes
|
||||
add_to_log($form->courseid, 'calendar', 'add', 'event.php?action=edit&id='.$eventid, $form->name);
|
||||
add_to_log($form->courseid, 'calendar', 'add', 'event.php?action=edit&id='.$eventid, stripslashes($form->name));
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user