fix backslash doubling on ical import

This commit is contained in:
Graham Knop 2007-11-07 18:53:40 +00:00
parent 70c557aa10
commit 8b23a6e7cf
2 changed files with 8 additions and 2 deletions

View file

@ -9,6 +9,7 @@
(Diona Kidd, Knowmad Technologies)
7.4.13
- fix: Calendar doubles backslashes on iCal import
- fix: EMS edit badge event list can display incorrectly in IE
- fix: Expired SessionScratch not deleted (thanks to Michelle Lamar)
http://www.plainblack.com/bugs/tracker/expired-sessionscratch-not-deleted

View file

@ -200,8 +200,8 @@ sub execute {
my $properties = {
feedUid => $id,
feedId => $feed->{feedId},
description => $events{$id}->{description}->[1],
title => $events{$id}->{summary}->[1],
description => _unwrapIcalText($events{$id}->{description}->[1]),
title => _unwrapIcalText($events{$id}->{summary}->[1]),
menuTitle => substr($events{$id}->{summary}->[1],0,15),
className => 'WebGUI::Asset::Event',
isHidden => 1,
@ -507,6 +507,11 @@ sub _icalToMySQL {
)->toMysql;
}
sub _unwrapIcalText {
my $text = shift;
$text =~ s/\\([.;\\])/$1/g;
return $text;
}
=head1 BUGS