Commit 3fe94bb1 authored by Hugo Sena Ribeiro's avatar Hugo Sena Ribeiro

avoid explicitly returning None

parent 2131ab25
......@@ -143,8 +143,6 @@ class DiffTreeStore(SearchableTreeStore):
self.set_state(it, pane, state, display_text, isdir)
def set_state(self, it, pane, state, label, isdir=0):
if not it:
return None
col_idx = self.column_index
icon = self.icon_details[state][1 if isdir else 0]
tint = self.icon_details[state][3 if isdir else 2]
......
......@@ -154,9 +154,10 @@ class SearchableTreeStore(Gtk.TreeStore):
return None
"""
if value is None and hasattr(self, '_none_of_cols'):
value = self._none_of_cols.get(column)
if value is None:
self.set_value(treeiter, column, value)
else:
_GIGtk.TreeStore.set_value(self, treeiter, column, value)
if treeiter:
if value is None and hasattr(self, '_none_of_cols'):
value = self._none_of_cols.get(column)
if value is None:
self.set_value(treeiter, column, value)
else:
_GIGtk.TreeStore.set_value(self, treeiter, column, value)
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment