polyrex-objects 0.7.7 → 0.7.8
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- checksums.yaml.gz.sig +0 -0
- data/lib/polyrex-objects.rb +4 -2
- data.tar.gz.sig +0 -0
- metadata +3 -3
- metadata.gz.sig +0 -0
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA1:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: cfc4b8dfea9f4bf7e413691c7fddf1e4ff97a50e
|
4
|
+
data.tar.gz: 6c9f49fee6caac5412ef963e64dea3001e011fd6
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 4ab488c7015cff2de067b58b37dee182ddc374444baa11e11a0771c51006687d4960620224ac7293b7e1e4b27a236b416d168a88d9924fb0912d530cbcb1d4cf
|
7
|
+
data.tar.gz: 99a9dcf84aa18ba439fe4752246f9387711464491ea66cfd83e56ed0d9f9179d8664295a85758930181da46d6332951adef2cd5a8b84a75d427a1afe8d648873
|
checksums.yaml.gz.sig
CHANGED
Binary file
|
data/lib/polyrex-objects.rb
CHANGED
@@ -9,6 +9,7 @@ require 'rexle'
|
|
9
9
|
|
10
10
|
class PolyrexObjects
|
11
11
|
|
12
|
+
|
12
13
|
class PolyrexObject
|
13
14
|
|
14
15
|
attr_reader :node, :id
|
@@ -58,7 +59,7 @@ class PolyrexObjects
|
|
58
59
|
|
59
60
|
def to_h()
|
60
61
|
@fields.inject({}) do |r, field|
|
61
|
-
r.merge(field => self.method(field).call)
|
62
|
+
r.merge(field.capitalize => self.method(field).call)
|
62
63
|
end
|
63
64
|
end
|
64
65
|
|
@@ -115,7 +116,8 @@ class PolyrexObjects
|
|
115
116
|
classx << " if @node.element('summary/#{field}').nil? then"
|
116
117
|
classx << " @node.element('summary').add Rexle::Element.new('#{field}')"
|
117
118
|
classx << " end"
|
118
|
-
classx << " @node.element('summary/#{field}/text()')
|
119
|
+
classx << " node = @node.element('summary/#{field}/text()')"
|
120
|
+
classx << " node ? node.clone : ''"
|
119
121
|
classx << "end"
|
120
122
|
classx << "def #{field}=(text)"
|
121
123
|
classx << " if @node.element('summary/#{field}').nil? then"
|
data.tar.gz.sig
CHANGED
Binary file
|
metadata
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: polyrex-objects
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.7.
|
4
|
+
version: 0.7.8
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- James Robertson
|
@@ -31,7 +31,7 @@ cert_chain:
|
|
31
31
|
C0ZUhP8IAGCVW8QD8AfZ/AgqUdh+zTRqKdhEyhXCjYyVXqNHnD02NbyGmQvgd9SD
|
32
32
|
XfuuGzQ3E4Mh5w==
|
33
33
|
-----END CERTIFICATE-----
|
34
|
-
date: 2014-
|
34
|
+
date: 2014-06-04 00:00:00.000000000 Z
|
35
35
|
dependencies:
|
36
36
|
- !ruby/object:Gem::Dependency
|
37
37
|
name: polyrex-createobject
|
@@ -74,7 +74,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
|
|
74
74
|
version: '0'
|
75
75
|
requirements: []
|
76
76
|
rubyforge_project:
|
77
|
-
rubygems_version: 2.
|
77
|
+
rubygems_version: 2.2.2
|
78
78
|
signing_key:
|
79
79
|
specification_version: 4
|
80
80
|
summary: polyrex-objects
|
metadata.gz.sig
CHANGED
Binary file
|