mods should return undef when there are no *mods* as well as when there is no mapping...
authorShawn Boyette <sboyette@esilibrary.com>
Fri, 24 Apr 2009 15:28:11 +0000 (15:28 +0000)
committerShawn Boyette <sboyette@esilibrary.com>
Fri, 24 Apr 2009 15:28:11 +0000 (15:28 +0000)
Equinox-Migration/lib/Equinox/Migration/SubfieldMapper.pm

index c7b5b6f..427a974 100644 (file)
@@ -184,6 +184,7 @@ will be returned.
 sub mods {
     my ($self, $field) = @_;
     return undef unless $self->has($field);
+    return undef unless (%{ $self->{fields}{$field}{mods} });
     return $self->{fields}{$field}{mods};
 }