Skip to content

Commit

Permalink
Use is_a? instead of inspect to cater to subclasses of Neography::Node
Browse files Browse the repository at this point in the history
  • Loading branch information
ujjwalt committed Oct 22, 2013
1 parent c6485db commit 47cba4c
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion lib/neography/index.rb
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,7 @@ module ClassMethods
def find(*args)
db = args[3] ? args.pop : Neography::Rest.new

if self.inspect == "Neography::Node"
if self.is_a?(Neography::Node)
nodes = []
results = db.find_node_index(*args)
return nil unless results
Expand Down

0 comments on commit 47cba4c

Please sign in to comment.