eric6/WebBrowser/GreaseMonkey/GreaseMonkeyScript.py

changeset 8143
2c730d5fd177
parent 7923
91e843545d9a
child 8218
7c09585bd960
diff -r 27f636beebad -r 2c730d5fd177 eric6/WebBrowser/GreaseMonkey/GreaseMonkeyScript.py
--- a/eric6/WebBrowser/GreaseMonkey/GreaseMonkeyScript.py	Mon Mar 01 17:48:43 2021 +0100
+++ b/eric6/WebBrowser/GreaseMonkey/GreaseMonkeyScript.py	Tue Mar 02 17:17:09 2021 +0100
@@ -361,7 +361,7 @@
         
         nspace = bytes(QCryptographicHash.hash(
             QByteArray(self.fullName().encode("utf-8")),
-            QCryptographicHash.Md4).toHex()).decode("ascii")
+            QCryptographicHash.Algorithm.Md4).toHex()).decode("ascii")
         valuesScript = values_js.format(nspace)
         self.__script = "(function(){{{0}\n{1}\n{2}\n}})();".format(
             valuesScript, self.__manager.requireScripts(self.__require),
@@ -505,5 +505,5 @@
             self.__iconReplies.remove(reply)
         
         reply.deleteLater()
-        if reply.error() == QNetworkReply.NoError:
+        if reply.error() == QNetworkReply.NetworkError.NoError:
             self.__icon = QPixmap.fromImage(QImage.fromData(reply.readAll()))

eric ide

mercurial