mirror of
git://github.com/kovidgoyal/calibre.git
synced 2025-12-28 11:29:08 +01:00
Book details: Fix a regression in the previous release that broke the right click search the internet function
Fixes #1842090 ["Search the internet for..." right-click options fail](https://bugs.launchpad.net/calibre/+bug/1842090)
This commit is contained in:
parent
05834f0b42
commit
1156e8209a
1 changed files with 2 additions and 0 deletions
|
|
@ -1145,6 +1145,8 @@ def open_url(qurl):
|
|||
|
||||
|
||||
def safe_open_url(qurl):
|
||||
if isinstance(qurl, string_or_bytes):
|
||||
qurl = QUrl(qurl)
|
||||
if qurl.scheme() in ('', 'file'):
|
||||
path = qurl.toLocalFile()
|
||||
ext = os.path.splitext(path)[-1].lower()[1:]
|
||||
|
|
|
|||
Loading…
Reference in a new issue