Skip to content

Commit

Permalink
Item12646: fixed use of deprecated perl syntax in foreach loops
Browse files Browse the repository at this point in the history
git-svn-id: http://svn.foswiki.org/trunk/ICalPlugin@17071 0b4bb1d4-4e5a-0410-9cc4-b2b747904278
  • Loading branch information
MichaelDaum authored and MichaelDaum committed Nov 7, 2013
1 parent a1023e7 commit 0919831
Show file tree
Hide file tree
Showing 5 changed files with 12 additions and 11 deletions.
2 changes: 1 addition & 1 deletion data/Sandbox/ICalHolidayListDemo.txt
@@ -1,4 +1,4 @@
%META:TOPICINFO{author="ProjectContributor" comment="save topic" date="1336488720" format="1.1" reprev="79" version="79"}%
%META:TOPICINFO{author="ProjectContributor" comment="autosave" date="1356288713" format="1.1" version="83"}%
%META:TOPICPARENT{name="WebHome"}%
---+!! %TOPIC%

Expand Down
4 changes: 2 additions & 2 deletions data/System/EventTopic.txt
@@ -1,6 +1,6 @@
%META:TOPICINFO{author="ProjectContributor" comment="save topic" date="1323784401" format="1.1" reprev="3" version="5"}%
%META:TOPICINFO{author="ProjectContributor" comment="autosave" date="1356278771" format="1.1" version="6"}%
%META:TOPICPARENT{name="WebHome"}%
---+!! %TOPICTITLE%
---+!! %TOPIC%

<noautolink>
| *Name* | *Type* | *Size* | *Values* | *Description* | *Atributes* |
Expand Down
5 changes: 3 additions & 2 deletions data/System/ICalPlugin.txt
@@ -1,4 +1,4 @@
%META:TOPICINFO{author="ProjectContributor" comment="reprev" date="1335348584" format="1.1" reprev="4" version="5"}%
%META:TOPICINFO{author="ProjectContributor" comment="autosave" date="1356278772" format="1.1" version="6"}%
---+!! %TOPIC%
%SHORTDESCRIPTION%

Expand Down Expand Up @@ -164,11 +164,12 @@ Finally, the standard foswiki escape variables are expanded:
-->

| Author(s): | Michael Daum|
| Copyright: | &copy; 2011-2012 Michael Daum http://michaeldaumconsulting.com |
| Copyright: | &copy; 2011-2013 Michael Daum http://michaeldaumconsulting.com |
| License: | [[http://www.gnu.org/licenses/gpl.html][GPL (Gnu General Public License)]] |
| Release: | %$RELEASE% |
| Version: | %$VERSION% |
| Change History: | <!-- versions below in reverse order -->&nbsp; |
| 07 Nov 2013 | fixed use of deprecated perl syntax in foreach loops |
| 21 Jun 2012 | fixed unintended redirect after save when accessing a view restricted data form |
| 08 May 2012 | fixed processing of weekly recurrences without a <nop>StartDate |
| 07 May 2012 | made dependency on Foswiki:Extensions/MetaDataPlugin optional |
Expand Down
6 changes: 3 additions & 3 deletions lib/Foswiki/Plugins/ICalPlugin.pm
@@ -1,6 +1,6 @@
# Plugin for Foswiki - The Free and Open Source Wiki, http://foswiki.org/
#
# ICalPlugin is Copyright (C) 2011-2012 Michael Daum http://michaeldaumconsulting.com
# ICalPlugin is Copyright (C) 2011-2013 Michael Daum http://michaeldaumconsulting.com
#
# This program is free software; you can redistribute it and/or
# modify it under the terms of the GNU General Public License
Expand All @@ -20,8 +20,8 @@ use warnings;

use Foswiki::Func ();

our $VERSION = '$Rev$';
our $RELEASE = '1.13';
our $VERSION = '1.14';
our $RELEASE = '1.14';
our $SHORTDESCRIPTION = 'Access ical data in wikiapps';
our $NO_PREFS_IN_TOPIC = 1;
our $core;
Expand Down
6 changes: 3 additions & 3 deletions lib/Foswiki/Plugins/ICalPlugin/Core.pm
@@ -1,6 +1,6 @@
# Plugin for Foswiki - The Free and Open Source Wiki, http://foswiki.org/
#
# ICalPlugin is Copyright (C) 2011-2012 Michael Daum http://michaeldaumconsulting.com
# ICalPlugin is Copyright (C) 2011-2013 Michael Daum http://michaeldaumconsulting.com
#
# This program is free software; you can redistribute it and/or
# modify it under the terms of the GNU General Public License
Expand Down Expand Up @@ -744,15 +744,15 @@ sub createEvent {
}

# other datetime properties
foreach my $prop qw(created dtstamp last-modified) {
foreach my $prop (qw(created dtstamp last-modified)) {
my $val = $params{$prop};
next unless defined $val;
$val = DateTime->from_epoch(epoch => parseTime($params{$prop}));
$vevent->add_properties($prop=>$val);
}

# optional unique
foreach my $prop qw(location organizer priority recurrence-id sequence status transp uid url) {
foreach my $prop (qw(location organizer priority recurrence-id sequence status transp uid url)) {
my $val = $params{$prop};
$vevent->add_properties($prop=>$val) if defined $val;
}
Expand Down

0 comments on commit 0919831

Please sign in to comment.