diff --git a/gramps/gen/plug/_manager.py b/gramps/gen/plug/_manager.py index 8fc4348f7..51bd85a2c 100644 --- a/gramps/gen/plug/_manager.py +++ b/gramps/gen/plug/_manager.py @@ -83,7 +83,7 @@ class BasePluginManager: def __init__(self): """ This function should only be run once by get_instance() """ - if BasePluginManager.__instance is not 1: + if BasePluginManager.__instance != 1: raise Exception("This class is a singleton. " "Use the get_instance() method") diff --git a/gramps/gen/plug/_pluginreg.py b/gramps/gen/plug/_pluginreg.py index b2e710fec..10c08db4d 100644 --- a/gramps/gen/plug/_pluginreg.py +++ b/gramps/gen/plug/_pluginreg.py @@ -1135,7 +1135,7 @@ class PluginRegister: def __init__(self): """ This function should only be run once by get_instance() """ - if PluginRegister.__instance is not 1: + if PluginRegister.__instance != 1: raise Exception("This class is a singleton. " "Use the get_instance() method") self.stable_only = True diff --git a/gramps/gui/pluginmanager.py b/gramps/gui/pluginmanager.py index df5748001..f2525304d 100644 --- a/gramps/gui/pluginmanager.py +++ b/gramps/gui/pluginmanager.py @@ -71,7 +71,7 @@ class GuiPluginManager(Callback): def __init__(self): """ This function should only be run once by get_instance() """ - if GuiPluginManager.__instance is not 1: + if GuiPluginManager.__instance != 1: raise Exception("This class is a singleton. " "Use the get_instance() method")