mirror of
https://github.com/pry/pry.git
synced 2022-11-09 12:35:05 -05:00
Merge pull request #1364 from pry/refactor/dont-throwaway-pry-instance
Use _pry_.pager if possible
This commit is contained in:
commit
6050a062c0
1 changed files with 5 additions and 1 deletions
|
@ -98,8 +98,12 @@ class Pry
|
||||||
# enabled). Infers where to send the output if used as a mixin.
|
# enabled). Infers where to send the output if used as a mixin.
|
||||||
# DEPRECATED.
|
# DEPRECATED.
|
||||||
def stagger_output(text, out = nil)
|
def stagger_output(text, out = nil)
|
||||||
|
if _pry_
|
||||||
|
_pry_.pager.page text
|
||||||
|
else
|
||||||
Pry.new.pager.page text
|
Pry.new.pager.page text
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
|
end
|
||||||
|
|
Loading…
Add table
Reference in a new issue