1
0
Fork 0
mirror of https://github.com/pry/pry.git synced 2022-11-09 12:35:05 -05:00

Pry::CodeObject: binding_lookup --> empty_lookup

This commit is contained in:
John Mair 2013-01-09 01:37:08 +01:00
parent 439c5c6811
commit 0608c0effa

View file

@ -27,7 +27,7 @@ class Pry
co = new(str, target, _pry_, options)
co.default_lookup || co.method_or_class_lookup ||
co.command_lookup || co.binding_lookup
co.command_lookup || co.empty_lookup
end
end
@ -38,7 +38,7 @@ class Pry
def initialize(str, target, _pry_, options={})
options = {
:super => 0
:super => 0,
}.merge!(options)
@str = str
@ -53,8 +53,7 @@ class Pry
pry.commands.find_command_by_match_or_listing(str) rescue nil
end
# extract the object from the binding
def binding_lookup
def empty_lookup
return nil if str && !str.empty?
if internal_binding?(target)