UI/UserInterface.py

changeset 2094
88620e11c67c
parent 1939
eadb2328d7d4
child 2101
5bac7dee9e1a
--- a/UI/UserInterface.py	Wed Oct 03 13:20:57 2012 +0200
+++ b/UI/UserInterface.py	Wed Oct 03 15:36:41 2012 +0200
@@ -5500,16 +5500,19 @@
         @param errors list of SSL errors (list of QSslError)
         """
         errorStrings = []
-        for err in errors:
-            errorStrings.append(err.errorString())
-        errorString = '.<br />'.join(errorStrings)
-        ret = E5MessageBox.yesNo(self,
-            self.trUtf8("SSL Errors"),
-            self.trUtf8("""<p>SSL Errors:</p>"""
-                        """<p>{0}</p>"""
-                        """<p>Do you want to ignore these errors?</p>""")\
-                .format(errorString),
-            icon=E5MessageBox.Warning)
+        if errors:
+            for err in errors:
+                errorStrings.append(err.errorString())
+            errorString = '.<br />'.join(errorStrings)
+            ret = E5MessageBox.yesNo(self,
+                self.trUtf8("SSL Errors"),
+                self.trUtf8("""<p>SSL Errors:</p>"""
+                            """<p>{0}</p>"""
+                            """<p>Do you want to ignore these errors?</p>""")\
+                    .format(errorString),
+                icon=E5MessageBox.Warning)
+        else:
+            ret = True
         if ret:
             reply.ignoreSslErrors()
         else:

eric ide

mercurial