Skip to content

Commit 0deb606

Browse files
committedJul 7, 2015
use active_branch method instead of accessing repo directly
1 parent accebd9 commit 0deb606

File tree

1 file changed

+1
-3
lines changed

1 file changed

+1
-3
lines changed
 

‎elasticgit/search.py

+1-3
Original file line numberDiff line numberDiff line change
@@ -89,9 +89,7 @@ class ReadWriteModelMappingType(ModelMappingTypeBase, Indexable):
8989

9090
@classmethod
9191
def get_index(cls):
92-
im = cls.im
93-
repo = cls.sm.repo
94-
return im.index_name(repo.active_branch.name)
92+
return cls.im.index_name(cls.sm.active_branch())
9593

9694
def get_object(self):
9795
return self.sm.get(self.model_class, self._id)

0 commit comments

Comments
 (0)
Please sign in to comment.