Helpviewer/Passwords/PasswordManager.py

changeset 5736
000ea446ff4b
parent 5597
3d88d53f8c2b
child 6048
82ad8ec9548c
diff -r f606dbe20be6 -r 000ea446ff4b Helpviewer/Passwords/PasswordManager.py
--- a/Helpviewer/Passwords/PasswordManager.py	Sat May 13 13:46:05 2017 +0200
+++ b/Helpviewer/Passwords/PasswordManager.py	Sat May 13 16:32:54 2017 +0200
@@ -12,7 +12,7 @@
 import os
 
 from PyQt5.QtCore import pyqtSignal, QObject, QByteArray, QUrl, \
-    QCoreApplication, QXmlStreamReader, qVersion
+    QCoreApplication, QXmlStreamReader
 from PyQt5.QtWidgets import QApplication
 from PyQt5.QtNetwork import QNetworkRequest
 from PyQt5.QtWebKit import QWebSettings
@@ -25,6 +25,7 @@
 import Utilities
 import Utilities.crypto
 import Preferences
+from Globals import qVersionTuple
 
 
 class PasswordManager(QObject):
@@ -437,7 +438,7 @@
         @return stripped URL (QUrl)
         """
         cleanUrl = QUrl(url)
-        if qVersion() >= "5.0.0":
+        if qVersionTuple() >= (5, 0, 0):
             cleanUrl.setQuery("")
         else:
             cleanUrl.setQueryItems([])
@@ -466,7 +467,7 @@
         if boundary is not None:
             args = self.__extractMultipartQueryItems(data, boundary)
         else:
-            if qVersion() >= "5.0.0":
+            if qVersionTuple() >= (5, 0, 0):
                 from PyQt5.QtCore import QUrlQuery
                 argsUrl = QUrl.fromEncoded(
                     QByteArray(b"foo://bar.com/?" + QUrl.fromPercentEncoding(

eric ide

mercurial