From 7213f1c5da6fffb0162a2405513d27e4a8273707 Mon Sep 17 00:00:00 2001 From: Conrad Irwin Date: Sun, 24 Mar 2013 23:01:44 -0700 Subject: [PATCH] Don't repeat if initial_session_setup fails --- lib/pry/pry_class.rb | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) diff --git a/lib/pry/pry_class.rb b/lib/pry/pry_class.rb index 24737d65..f5bdcb41 100644 --- a/lib/pry/pry_class.rb +++ b/lib/pry/pry_class.rb @@ -114,7 +114,8 @@ class Pry # loading history. def self.initial_session_setup - return if !initial_session? + return unless initial_session? + @initial_session = false # note these have to be loaded here rather than in pry_instance as # we only want them loaded once per entire Pry lifetime. @@ -123,8 +124,6 @@ class Pry load_requires if Pry.config.should_load_requires load_history if Pry.config.history.should_load load_traps if Pry.config.should_trap_interrupts - - @initial_session = false end # Start a Pry REPL.