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

Hacky fix for bug where command_state isn't initialized before cding

This commit is contained in:
Ryan Fitzgerald 2012-12-23 00:12:07 -08:00
parent 3c6ffaf69c
commit f82cd1535e

View file

@ -120,6 +120,7 @@ class Pry
else
# Otherwise, saves current binding stack as old stack and pops last
# binding out of binding stack (the old stack still has that binding).
_pry_.command_state["cd"] ||= OpenStruct.new # FIXME
_pry_.command_state["cd"].old_stack = _pry_.binding_stack.dup
_pry_.binding_stack.pop
end