Fixed unnecessary comparisons

This commit is contained in:
Doug Blank 2016-01-23 18:45:54 -05:00
parent 74ab1ba874
commit 32b8005e0e
4 changed files with 4 additions and 4 deletions

View File

@ -1644,7 +1644,7 @@ class MultiTreeView(Gtk.TreeView):
self.uistate, [], ref)
except WindowActiveError:
pass
elif objclass in ['Media', 'Media']:
elif objclass == 'Media':
ref = self.dbstate.db.get_object_from_handle(handle)
if ref:
try:

View File

@ -256,7 +256,7 @@ class QuickTable(SimpleTable):
return True # handled event
except WindowActiveError:
pass
elif objclass in ['Media', 'Media']:
elif objclass == 'Media':
ref = self.access.dbase.get_object_from_handle(handle)
if ref:
try:

View File

@ -40,7 +40,7 @@ def SelectorFactory(classname):
elif classname == 'Citation':
from .selectcitation import SelectCitation
cls = SelectCitation
elif classname in ['Media', 'Media']:
elif classname == 'Media':
from .selectobject import SelectObject
cls = SelectObject
elif classname == 'Repository':

View File

@ -48,7 +48,7 @@ def get_ref(db, objclass, handle):
ref = db.get_place_from_handle(handle)
elif objclass == 'Note':
ref = db.get_note_from_handle(handle)
elif objclass in ['Media', 'Media']:
elif objclass == 'Media':
ref = db.get_object_from_handle(handle)
else:
ref = objclass