oai 0.0.11 → 0.0.12

Sign up to get free protection for your applications and to get access to all the features.
data/README CHANGED
@@ -78,3 +78,4 @@ Where x.y.z is the version of the gem that was generated.
78
78
 
79
79
  - Ed Summers <ehs@pobox.com>
80
80
  - William Groppe <will.groppe@gmail.com>
81
+ - Terry Reese <terry.reese@oregonstate.edu>
data/Rakefile CHANGED
@@ -1,4 +1,4 @@
1
- RUBY_OAI_VERSION = '0.0.11'
1
+ RUBY_OAI_VERSION = '0.0.12'
2
2
 
3
3
  require 'rubygems'
4
4
  require 'rake'
@@ -21,7 +21,11 @@ module OAI
21
21
  if defined?(error.property) == nil
22
22
  code = error.attributes['code']
23
23
  else
24
- code.property('code')
24
+ begin
25
+ code = error["code"]
26
+ rescue
27
+ code = error.property('code')
28
+ end
25
29
  end
26
30
  end
27
31
  raise OAI::Exception.new(message, code)
data/lib/oai/xpath.rb CHANGED
@@ -42,7 +42,13 @@ module OAI
42
42
  if defined?(node.property) == nil
43
43
  return node.attributes[attr_name]
44
44
  else
45
- return node.property(attr_name)
45
+ #node.property is being deprecated. We'll eventually remove
46
+ #this trap
47
+ begin
48
+ return node[attr_name]
49
+ rescue
50
+ return node.property(attr_name)
51
+ end
46
52
  end
47
53
  end
48
54
  return nil
metadata CHANGED
@@ -3,8 +3,8 @@ rubygems_version: 0.9.4
3
3
  specification_version: 1
4
4
  name: oai
5
5
  version: !ruby/object:Gem::Version
6
- version: 0.0.11
7
- date: 2008-09-19 00:00:00 -07:00
6
+ version: 0.0.12
7
+ date: 2008-12-22 00:00:00 -08:00
8
8
  summary: A ruby library for working with the Open Archive Initiative Protocol for Metadata Harvesting (OAI-PMH)
9
9
  require_paths:
10
10
  - lib