Skip to content

Commit

Permalink
Item9825: Fixed plugin for 1.1.0 compatibility
Browse files Browse the repository at this point in the history
git-svn-id: http://svn.foswiki.org/trunk/ActionTrackerPlugin@9577 0b4bb1d4-4e5a-0410-9cc4-b2b747904278
  • Loading branch information
KennethLavrsen authored and KennethLavrsen committed Oct 17, 2010
1 parent e41b5df commit 48654b9
Show file tree
Hide file tree
Showing 4 changed files with 24 additions and 3 deletions.
1 change: 1 addition & 0 deletions data/System/ActionTrackerPlugin.txt
Original file line number Diff line number Diff line change
Expand Up @@ -485,6 +485,7 @@ Thanks are due to the following sponsors, who have helped make this plugin possi
| Copyright | Copyright © 2002-2003 Motorola. All Rights Reserved.%BR% Copyright © 2004-2009 Crawford Currie |
| License: | GPL ([[http://www.gnu.org/copyleft/gpl.html][GNU General Public License]]) |
| Change History: | |
| 17 Oct 2010 | Foswiki:Tasks/Item9825: Update for Foswiki 1.1.0 compatibility. No other fixes in this revision |
| 07 Feb 2010 | Foswiki:Tasks/Item8362: fix table separator in IE -- Foswiki:Main.AndrewJones |
| 20 Jan 2010 | Foswiki:Tasks/Item8400: fix for editing in the plugin topic page |
| 4 Jan 2010 | Foswiki:Tasks/Item8376: doc fix |
Expand Down
2 changes: 1 addition & 1 deletion lib/Foswiki/Plugins/ActionTrackerPlugin.pm
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,7 @@ use Foswiki::Func ();
use Foswiki::Plugins ();

our $VERSION = '$Rev$';
our $RELEASE = '07 Feb 2010';
our $RELEASE = '17 Oct 2010';
our $SHORTDESCRIPTION =
'Adds support for action tags in topics, and automatic notification of action statuses';
our $initialised = 0;
Expand Down
14 changes: 12 additions & 2 deletions lib/Foswiki/Plugins/ActionTrackerPlugin/ActionNotify.pm
Original file line number Diff line number Diff line change
Expand Up @@ -481,9 +481,19 @@ sub _findChangesInWeb {
}
);

foreach my $topic ( keys %$grep ) {
_findChangesInTopic( $web, $topic, $theDate, $format, $notifications );
if( ref( $grep ) eq 'HASH' ) {
foreach my $topic ( keys %$grep ) {
_findChangesInTopic( $web, $topic, $theDate, $format, $notifications );
}
}
else {
while( $grep->hasNext() ) {
my $webtopic = $grep->next();
my ($foundWeb, $topic) = Foswiki::Func::normalizeWebTopicName($web, $webtopic);
_findChangesInTopic( $web, $topic, $theDate, $format, $notifications );
}
}

}

# PRIVATE STATIC
Expand Down
10 changes: 10 additions & 0 deletions lib/Foswiki/Plugins/ActionTrackerPlugin/ActionSet.pm
Original file line number Diff line number Diff line change
Expand Up @@ -303,6 +303,16 @@ sub allActionsInWeb {
}
);

if( ref( $grep ) ne 'HASH' ) { # New Func implementation
my %oldResultSet;
while( $grep->hasNext() ) {
my $webtopic = $grep->next();
my ($foundWeb, $topic) = Foswiki::Func::normalizeWebTopicName($web, $webtopic);
$oldResultSet{$topic} = 1;
}
$grep = \%oldResultSet;
}

foreach my $topic ( keys %$grep ) {
# SMELL: always read the text, because it's faster in the current
# impl to find the perms embedded in it
Expand Down

0 comments on commit 48654b9

Please sign in to comment.