Skip to content

Commit

Permalink
Remove unused text_exist() methods. Refs #198
Browse files Browse the repository at this point in the history
  • Loading branch information
atodorov committed Jun 26, 2018
1 parent 8cc43d6 commit 77077dd
Show file tree
Hide file tree
Showing 2 changed files with 0 additions and 11 deletions.
3 changes: 0 additions & 3 deletions tcms/testcases/models.py
Original file line number Diff line number Diff line change
Expand Up @@ -481,9 +481,6 @@ def latest_text_version(self):
qs = self.text.order_by('-case_text_version').only('case_text_version')[0:1]
return 0 if len(qs) == 0 else qs[0].case_text_version

def text_exist(self):
return self.text.exists()

def text_checksum(self):
qs = self.text.order_by('-case_text_version').only('action_checksum',
'effect_checksum',
Expand Down
8 changes: 0 additions & 8 deletions tcms/testplans/models.py
Original file line number Diff line number Diff line change
Expand Up @@ -103,14 +103,6 @@ def latest_text(self):
except ObjectDoesNotExist:
return None

def text_exist(self):
try:
return self.text.exists()
except IndexError:
return False
except ObjectDoesNotExist:
return False

def text_checksum(self):
try:
return self.text.order_by('-pk').only('checksum')[0].checksum
Expand Down

0 comments on commit 77077dd

Please sign in to comment.