popcap 0.9.0 → 0.9.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- checksums.yaml +4 -4
- data/lib/pop_cap/tag_struct.rb +2 -4
- data/lib/pop_cap/version.rb +1 -1
- metadata +1 -1
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA1:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: f501af71b14eab9cff56922ad86d1fee90ec7708
|
4
|
+
data.tar.gz: 97f10f4e8c30933e78d4922ff21232d8e6466a4d
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 75e71de1d63cf22702446139ea76813f09630663ef56d51c13f924a06521fa70f473536ed1517e1b9d413eec12abc1e80ab3a0758bce56e0b450c553625f5263
|
7
|
+
data.tar.gz: e50eeafcb45b0f6d545a883def105c6507215eb43fa0300aed436aa633cb160678c104c18ec3b7a09a954b029c6333df99730219c7db9b35bf618491998b85cf
|
data/lib/pop_cap/tag_struct.rb
CHANGED
@@ -16,7 +16,6 @@ module PopCap
|
|
16
16
|
def initialize(hash)
|
17
17
|
raise(ArgumentError, argument_error_message) unless hash.kind_of?(Hash)
|
18
18
|
@hash = hash
|
19
|
-
@tags = {}
|
20
19
|
define_instance_methods
|
21
20
|
end
|
22
21
|
|
@@ -35,8 +34,8 @@ module PopCap
|
|
35
34
|
# Public: This method is a custom each iterator for tags.
|
36
35
|
#
|
37
36
|
def each(&block)
|
38
|
-
@
|
39
|
-
block_given? ? block.call(
|
37
|
+
@hash.each do |elem|
|
38
|
+
block_given? ? block.call(elem) : elem
|
40
39
|
end
|
41
40
|
end
|
42
41
|
|
@@ -49,7 +48,6 @@ module PopCap
|
|
49
48
|
@hash.each do |key, val|
|
50
49
|
unless self.class.respond_to? key
|
51
50
|
define_singleton_method(key) { val }
|
52
|
-
@tags[key] = val
|
53
51
|
end
|
54
52
|
end
|
55
53
|
end
|
data/lib/pop_cap/version.rb
CHANGED