Move binary operators to start of line
authorKarl O. Pinc <kop@meme.com>
Wed, 24 Oct 2018 20:50:49 +0000 (15:50 -0500)
committerKarl O. Pinc <kop@meme.com>
Wed, 24 Oct 2018 20:50:49 +0000 (15:50 -0500)
src/pgwui_core/pgwui_core.py

index a09c16ba4706aa7e1b22f06a8d771377007e0882..fe14ccf84223b255e8eb1f2576e35d6842301034 100644 (file)
@@ -289,8 +289,8 @@ class CredsLoadedForm(LoadedForm):
         Produces the dict pyramid will use to render the form.
         '''
         response = super(CredsLoadedForm, self).write(result, errors)
-        if ('havecreds' not in response or
-                ('havecreds' in response and not response['havecreds'])):
+        if ('havecreds' not in response
+                or ('havecreds' in response and not response['havecreds'])):
             # We don't know if the credentials are good or
             # we know they are bad.  Keep them out of the session.
             response['user'] = ''
@@ -1421,8 +1421,8 @@ class UploadHandler(SessionDBHandler):
         if hasattr(self, 'data'):
             response['lines'] = self.data.lineno - 1
         response['e_cnt'] = len(errors)
-        response['db_changed'] = (not response['errors'] and
-                                  self.uf['action'] != '')
+        response['db_changed'] = (not response['errors']
+                                  and self.uf['action'] != '')
         return response