Skip to content

Commit

Permalink
fix default value in interactiveshell.ask_yes_no
Browse files Browse the repository at this point in the history
was True, should be None

closes #1026
  • Loading branch information
minrk committed Nov 21, 2011
1 parent 6c20358 commit 30385c4
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 2 deletions.
2 changes: 1 addition & 1 deletion IPython/core/interactiveshell.py
Expand Up @@ -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)
Expand Down
3 changes: 2 additions & 1 deletion IPython/core/magic.py
Expand Up @@ -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
Expand Down

0 comments on commit 30385c4

Please sign in to comment.