mirror of
https://github.com/kovidgoyal/calibre.git
synced 2025-07-09 03:04:10 -04:00
Use expanduser instead of env vars.
This commit is contained in:
parent
15816210ca
commit
7036d1acc1
@ -48,7 +48,7 @@ class NPWebView(QWebView):
|
||||
basename = br.open(url).geturl().split('/')[-1]
|
||||
ext = os.path.splitext(basename)[1][1:].lower()
|
||||
if ext not in BOOK_EXTENSIONS:
|
||||
home = os.getenv('USERPROFILE') or os.getenv('HOME')
|
||||
home = os.path.expanduser('~')
|
||||
name = QFileDialog.getSaveFileName(self,
|
||||
_('File is not a supported ebook type. Save to disk?'),
|
||||
os.path.join(home, basename),
|
||||
|
Loading…
x
Reference in New Issue
Block a user