rexle 1.0.10 → 1.0.11

Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA1:
3
- metadata.gz: e786ad00115c83c771c8282bf7578744c8ba32e6
4
- data.tar.gz: f6727813960207805cd939fd2775319aff07e3a8
3
+ metadata.gz: c02a1ffb1246a1e8def0ba33ab1a4ee3ea1baf24
4
+ data.tar.gz: 90b4c3463fe307025e912d6720467e6de85d22d9
5
5
  SHA512:
6
- metadata.gz: 42cda03862eff07537e4f6b2277d44077ff3f22214c98cc8ce4e2fc68d763f23057fb27731a1b48d0ad518c29155c34ef94876f844cd9caed07f1abd01c05891
7
- data.tar.gz: fef068c36f7bc9369d3ecfb06fb0e75c7c5d6197f6f1a7070e97d0e37dcf119100beac97c30ab4566b7067cbd4b27ca06a5a5b35c8399d366b8a719cee5e8ce0
6
+ metadata.gz: b4e9f0fe998a37ccc7e4fd7bdbf5510c1924dac0e60fa08097073e809c586391dc6b1bc36ccdbcb32d675a08ce74993651d3fe436ae860eed94e84dd27ad927b
7
+ data.tar.gz: bdf1ff525603447996787f488b7fd51bd088d81ca35723e2a4f1657689717bcb3d3b35366b9823a72d91e5c6c1f3824e32d73acf3482143cc83e2e912fea187e
checksums.yaml.gz.sig CHANGED
Binary file
data/lib/rexle.rb CHANGED
@@ -11,7 +11,9 @@ include REXML
11
11
 
12
12
  # modifications:
13
13
 
14
- # 03-Jun-2013: bug fix: Text elements are now nil by default
14
+ # 04-Jun-2014: bug fix: If XPath contains /text(), only valid
15
+ # text elements are returned
16
+ # 03-Jun-2014: bug fix: Text elements are now nil by default
15
17
  # 01-Jun-2014: bug fix: XPath elements separated by a pipe '|' are now
16
18
  # stripped of white space
17
19
  # 20-May-2014: feature: XPath Descendants after the element (or without
@@ -440,6 +442,7 @@ class Rexle
440
442
 
441
443
  end
442
444
 
445
+
443
446
  if return_elements.length > 0 then
444
447
 
445
448
  if (a_path + [remaining_path]).join.empty? then
@@ -451,7 +454,12 @@ class Rexle
451
454
 
452
455
  rlist << return_elements.map.with_index do |x,i|
453
456
 
454
- rtn_element = filter(x, i+1, attr_search){|e| r = e.xpath(a_path.join('/') + raw_condition.to_s + remaining_path, &blk); (r || e) }
457
+ rtn_element = filter(x, i+1, attr_search) do |e|
458
+ r = e.xpath(a_path.join('/') + raw_condition.to_s \
459
+ + remaining_path, &blk)
460
+ #(r || e)
461
+ end
462
+
455
463
  next if rtn_element.nil? or (rtn_element.is_a? Array and rtn_element.empty?)
456
464
 
457
465
  if rtn_element.is_a? Hash then
data.tar.gz.sig CHANGED
Binary file
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: rexle
3
3
  version: !ruby/object:Gem::Version
4
- version: 1.0.10
4
+ version: 1.0.11
5
5
  platform: ruby
6
6
  authors:
7
7
  - James Robertson
@@ -31,7 +31,7 @@ cert_chain:
31
31
  UOGKUMV5RApHDnC0ywMYNe0HK7qMSTP5YLKs8JUjNxpc5jl8+o3D3sHkNN4DzbQm
32
32
  jVfzDZ+niKvAUA==
33
33
  -----END CERTIFICATE-----
34
- date: 2014-06-03 00:00:00.000000000 Z
34
+ date: 2014-06-04 00:00:00.000000000 Z
35
35
  dependencies:
36
36
  - !ruby/object:Gem::Dependency
37
37
  name: rexleparser
metadata.gz.sig CHANGED
Binary file