X-Git-Url: https://harishankar.org/repos/?p=biaweb_qt.git;a=blobdiff_plain;f=templates_dialog.py;fp=templates_dialog.py;h=db61404f0ef15560705d79afa918ab651eaa6958;hp=20f2e18e76b88d7a4a8021aa31f0392a2310f7ba;hb=1e98086e7040991b7aa6904fbac30f256a84f299;hpb=cd074c8da38f6cc0ad808783ca7e631967dfdd47 diff --git a/templates_dialog.py b/templates_dialog.py index 20f2e18..db61404 100644 --- a/templates_dialog.py +++ b/templates_dialog.py @@ -35,7 +35,7 @@ class TemplatesDialog (PyQt4.QtGui.QDialog, ui_templates_dialog.Ui_TemplatesDial tpl_str = biaweb_db.get_template_text (self.current_db, tpl_name) # if template string cannot be obtained for some reason - if tpl_str == False: + if tpl_str is False: PyQt4.QtGui.QMessageBox.critical (self, "Error", "SQLite 3 error in retrieving template") else: # open edit dialog with title "template name" and text as the template string @@ -47,6 +47,6 @@ class TemplatesDialog (PyQt4.QtGui.QDialog, ui_templates_dialog.Ui_TemplatesDial # update the template with the new template string ret = biaweb_db.update_template (self.current_db, tpl_name, upd_tpl_str) # if update failed - if ret == False: + if ret is False: PyQt4.QtGui.QMessageBox.critical (self, "Error", "SQLite 3 error in updating template")