Skip to content

Commit

Permalink
Item11416: cmp isn't numeric, thanks Babar
Browse files Browse the repository at this point in the history
git-svn-id: http://svn.foswiki.org/trunk/TopicDataHelperPlugin@13567 0b4bb1d4-4e5a-0410-9cc4-b2b747904278
  • Loading branch information
PaulHarvey authored and PaulHarvey committed Jan 9, 2012
1 parent 996ede7 commit b5f6114
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 4 deletions.
2 changes: 1 addition & 1 deletion data/System/TopicDataHelperPlugin.txt
Expand Up @@ -517,7 +517,7 @@ my $text = join "\n", @$list;
| Version: | %$VERSION% |
| Release: | %$RELEASE% |
| Change History: | <!-- versions below in reverse order --> |
| 09 Jan 2012 | V.1.1.3 Paul Harvey: Fix perl 5.12+ =Use of uninitialized value in lc= warnings, \
| 09 Jan 2012 | V.1.1.4 Paul Harvey: Fix perl 5.12+ =Use of uninitialized value in lc= warnings, \
fix code testing for compare mode 'integer' vs incorrect API doc 'numeric' (now works with both) |
| 01 Apr 2010 | V.1.1.2 Arthur Clemens: Allow topic data to be used without data structure. |
| 20 Jun 2009 | V.1.1.1 Arthur Clemens: Fixed reading of =web.topic= notation in =createTopicData=. |
Expand Down
6 changes: 3 additions & 3 deletions lib/Foswiki/Plugins/TopicDataHelperPlugin.pm
Expand Up @@ -20,7 +20,7 @@ use Assert;
use Foswiki::Func();

our $VERSION = '$Rev$';
our $RELEASE = '1.1.3';
our $RELEASE = '1.1.4';
our $SHORTDESCRIPTION =
'helper plugin for collecting, filtering and sorting data objects';
our $NO_PREFS_IN_TOPIC = 1;
Expand Down Expand Up @@ -690,15 +690,15 @@ sub _sortObjectsByProperty {
sort {
( $a->{$inSortKey} || 0 ) <=> ( $b->{$inSortKey} || 0 )
|| # secondary key hardcoded
( $a->{$inSecondaryKey} || 0 ) cmp ( $b->{$inSecondaryKey} || 0 )
( $a->{$inSecondaryKey} || '' ) cmp ( $b->{$inSecondaryKey} || '' )
} @objectData;
}
else {
@sortedObjects =
sort {
( $b->{$inSortKey} || 0 ) <=> ( $a->{$inSortKey} || 0)
|| # secondary key hardcoded
( $b->{$inSecondaryKey} || 0 ) cmp ( $a->{$inSecondaryKey} || 0 )
( $b->{$inSecondaryKey} || '' ) cmp ( $a->{$inSecondaryKey} || '' )
} @objectData;
}
}
Expand Down

0 comments on commit b5f6114

Please sign in to comment.