Skip to content
This repository has been archived by the owner on Jul 1, 2021. It is now read-only.

Commit

Permalink
nokogiri attributes workaround support for 1.6.x
Browse files Browse the repository at this point in the history
  • Loading branch information
dekz committed Jan 31, 2014
1 parent 53e833a commit 571433c
Showing 1 changed file with 7 additions and 1 deletion.
8 changes: 7 additions & 1 deletion lib/rbvmomi/deserialization.rb
Original file line number Diff line number Diff line change
Expand Up @@ -42,7 +42,13 @@ def initialize conn
end

def deserialize node, type=nil
type_attr = node['type']
if type_attr = node['type']
elsif node.attributes['type']
# Work around for 1.5.x which doesn't populate node['type']
# XXX what changed
type_attr = node.attributes['type'].value
end

type = type_attr if type_attr

if action = BUILTIN_TYPE_ACTIONS[type]
Expand Down

0 comments on commit 571433c

Please sign in to comment.