mongoid-tags-arent-hard 1.1.0 → 1.1.1
Sign up to get free protection for your applications and to get access to all the features.
data/README.md
CHANGED
@@ -13,7 +13,7 @@ module Mongoid
|
|
13
13
|
end
|
14
14
|
|
15
15
|
def normalize(*tag_list)
|
16
|
-
x = tag_list.flatten.map {|s| s.split(self.options[:separator]).map {|x| x.strip}}.flatten
|
16
|
+
x = tag_list.flatten.compact.map {|s| s.split(self.options[:separator]).map {|x| x.strip}}.flatten
|
17
17
|
return x
|
18
18
|
end
|
19
19
|
|
@@ -52,6 +52,11 @@ describe Mongoid::TagsArentHard::Tags do
|
|
52
52
|
tags.should eql(["foo", "bar", "baz"])
|
53
53
|
end
|
54
54
|
|
55
|
+
it "does not raise exception on nil tags" do
|
56
|
+
lambda {tags << nil}.should_not raise_exception
|
57
|
+
lambda {tags << ["1", "2", nil, "3"]}.should_not raise_exception
|
58
|
+
end
|
59
|
+
|
55
60
|
end
|
56
61
|
|
57
62
|
describe '+' do
|
metadata
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: mongoid-tags-arent-hard
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 1.1.
|
4
|
+
version: 1.1.1
|
5
5
|
prerelease:
|
6
6
|
platform: ruby
|
7
7
|
authors:
|
@@ -9,7 +9,7 @@ authors:
|
|
9
9
|
autorequire:
|
10
10
|
bindir: bin
|
11
11
|
cert_chain: []
|
12
|
-
date: 2012-
|
12
|
+
date: 2012-11-09 00:00:00.000000000 Z
|
13
13
|
dependencies:
|
14
14
|
- !ruby/object:Gem::Dependency
|
15
15
|
name: mongoid
|