polyblock 0.3.1 → 0.3.2
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/app/helpers/polyblock/application_helper.rb +6 -1
- data/lib/polyblock/version.rb +1 -1
- metadata +1 -3
- data/test/dummy/tmp/pids/server.pid +0 -1
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA1:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 21a692470d1350ca6dd6b68ce45313f43d753c66
|
4
|
+
data.tar.gz: 4e4fa9f06f01c46bf8f3ad98de430fcf1974caa2
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: b8b4994a2488cd7e7d7d193fa0c9c8ab8beee99b667603e10736f427f41af96a815b2d0b3063ce9b78d518c20d83bd008693285571cb5a62a55c6dbb7bc9dd3c
|
7
|
+
data.tar.gz: de796291fa0eafbad3c7d0dcd689c4b0d09aa560b3a9f2181e08015df2c5467d8222ffdc73d40b9b3fb5bf5d6852e93e2d0e28924c7f9f5b5e85b0f56a312d89
|
@@ -20,7 +20,12 @@ module Polyblock
|
|
20
20
|
matches = Polyblock::Block.where :name => name
|
21
21
|
pb_exists = matches.any?
|
22
22
|
pb = pb_exists ? matches.first : Polyblock::Block.new({:name => name})
|
23
|
-
pb_id = pb_exists
|
23
|
+
pb_id = if pb_exists
|
24
|
+
pb.id
|
25
|
+
else
|
26
|
+
nextId = Polyblock::Block.count + 1
|
27
|
+
nextId += 1 while Polyblock::Block.where(:id => nextId).any?
|
28
|
+
end
|
24
29
|
end
|
25
30
|
|
26
31
|
# Build output tag
|
data/lib/polyblock/version.rb
CHANGED
metadata
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: polyblock
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.3.
|
4
|
+
version: 0.3.2
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- MacKinley Smith
|
@@ -1493,7 +1493,6 @@ files:
|
|
1493
1493
|
- test/dummy/tmp/cache/assets/development/sprockets/ff61dbc17d234bd987651f689838d26a
|
1494
1494
|
- test/dummy/tmp/cache/assets/development/sprockets/ffdb359321552b05439e0337844f817d
|
1495
1495
|
- test/dummy/tmp/cache/assets/development/sprockets/fffa8f692e900a66d630702707280ecc
|
1496
|
-
- test/dummy/tmp/pids/server.pid
|
1497
1496
|
- test/fixtures/polyblock/blocks.yml
|
1498
1497
|
- test/helpers/polyblock/polyblocks_helper_test.rb
|
1499
1498
|
- test/integration/navigation_test.rb
|
@@ -2814,7 +2813,6 @@ test_files:
|
|
2814
2813
|
- test/dummy/tmp/cache/assets/development/sprockets/ff61dbc17d234bd987651f689838d26a
|
2815
2814
|
- test/dummy/tmp/cache/assets/development/sprockets/ffdb359321552b05439e0337844f817d
|
2816
2815
|
- test/dummy/tmp/cache/assets/development/sprockets/fffa8f692e900a66d630702707280ecc
|
2817
|
-
- test/dummy/tmp/pids/server.pid
|
2818
2816
|
- test/fixtures/polyblock/blocks.yml
|
2819
2817
|
- test/helpers/polyblock/polyblocks_helper_test.rb
|
2820
2818
|
- test/integration/navigation_test.rb
|
@@ -1 +0,0 @@
|
|
1
|
-
48499
|