polyrex-links 0.1.2 → 0.1.3

Sign up to get free protection for your applications and to get access to all the features.
Files changed (2) hide show
  1. data/lib/polyrex-links.rb +2 -2
  2. metadata +1 -1
data/lib/polyrex-links.rb CHANGED
@@ -22,12 +22,12 @@ class PolyrexLinks
22
22
 
23
23
  mask = "records/link[summary/name='%s']"
24
24
 
25
- do
25
+ begin
26
26
  c = a2.shift; xpath = c.map{|x| mask % x}.join + '/summary/url/text()'
27
27
  r = @polyrex.element xpath
28
28
  end until r or a2.empty?
29
29
 
30
- r + path.sub(c.join('/'),'')
30
+ r ? r + path.sub(c.join('/'),'') : nil
31
31
  end
32
32
 
33
33
  def to_xml(options={})
metadata CHANGED
@@ -2,7 +2,7 @@
2
2
  name: polyrex-links
3
3
  version: !ruby/object:Gem::Version
4
4
  prerelease:
5
- version: 0.1.2
5
+ version: 0.1.3
6
6
  platform: ruby
7
7
  authors:
8
8
  - James Robertson