Commit a86a37e9 authored by Michal Čihař's avatar Michal Čihař

Fix fetching of last author

parent a585cb14
......@@ -375,9 +375,9 @@ class Translation(models.Model):
def get_last_author(self):
try:
change = self.change_set.order_by('-timestamp')[0]
change = Change.objects.filter(unit__translation = self).order_by('-timestamp')[0]
return self.get_author_name(change.user)
except:
except IndexError:
return None
def check_commit_needed(self, author):
......
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