Permalink
Browse files

fix default value in interactiveshell.ask_yes_no

was True, should be None

closes #1026
  • Loading branch information...
minrk committed Nov 21, 2011
1 parent 6c20358 commit 30385c4ef55446d7213fd0da7a8ee35e39127bb7
Showing with 3 additions and 2 deletions.
  1. +1 −1 IPython/core/interactiveshell.py
  2. +2 −1 IPython/core/magic.py
@@ -2616,7 +2616,7 @@ def write_err(self,data):
"""Write a string to the default error output"""
io.stderr.write(data)
- def ask_yes_no(self,prompt,default=True):
+ def ask_yes_no(self, prompt, default=None):
if self.quiet:
return True
return ask_yes_no(prompt,default)
View
@@ -1058,7 +1058,8 @@ def magic_reset_selective(self, parameter_s=''):
ans = True
else:
ans = self.shell.ask_yes_no(
- "Once deleted, variables cannot be recovered. Proceed (y/[n])? ")
+ "Once deleted, variables cannot be recovered. Proceed (y/[n])? ",
+ default='n')
if not ans:
print 'Nothing done.'
return

0 comments on commit 30385c4

Please sign in to comment.