From b509791910a6e65db600bc1c31ba3da1fdefd116 Mon Sep 17 00:00:00 2001 From: Bob Farrell Date: Tue, 29 Apr 2008 02:05:24 +0100 Subject: [PATCH] expanduser more correct Now it checks if fn.startswith('~'), rather than checking if there's a ~ in the string at all. --- bpython.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/bpython.py b/bpython.py index 865abc8..e6f53d7 100644 --- a/bpython.py +++ b/bpython.py @@ -510,7 +510,7 @@ class Repl: fn = self.statusbar.prompt( 'Save to file: ' ) - if '~' in fn: + if fn.startswith('~'): fn = os.path.expanduser( fn ) s = self.getstdout()