[Jifty-commit] r5903 - jifty/trunk/lib/Jifty/Action/Record
Jifty commits
jifty-commit at lists.jifty.org
Sun Oct 5 02:43:57 EDT 2008
Author: sunnavy
Date: Sun Oct 5 02:43:56 2008
New Revision: 5903
Modified:
jifty/trunk/lib/Jifty/Action/Record/Bulk.pm
Log:
filter ids arg to get rid of 0
Modified: jifty/trunk/lib/Jifty/Action/Record/Bulk.pm
==============================================================================
--- jifty/trunk/lib/Jifty/Action/Record/Bulk.pm (original)
+++ jifty/trunk/lib/Jifty/Action/Record/Bulk.pm Sun Oct 5 02:43:56 2008
@@ -88,7 +88,8 @@
sub take_action {
my $self = shift;
my $ids = $self->argument_value('ids');
- $ids = [split /,/,$ids] if !ref($ids);
+ # ids can be '0', and we don't want to keep '0'
+ $ids = [ grep { $_ ne 0 } split /,/,$ids] if !ref($ids);
for (@{$self->actions}) {
my ($action_class, $param) = @$_;
# XXX: create real action objects and invoke them, so we have separate result objects
More information about the Jifty-commit
mailing list