Skip to content

Commit

Permalink
refactor blast view functions
Browse files Browse the repository at this point in the history
  • Loading branch information
carlosp420 committed Jan 9, 2015
1 parent b425ab9 commit 2a2ddf7
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 8 deletions.
5 changes: 1 addition & 4 deletions voseq/blast_local/views.py
Original file line number Diff line number Diff line change
Expand Up @@ -7,11 +7,8 @@ def index(request, voucher_code, gene_code):
blast = BLAST('local', voucher_code, gene_code)
blast.save_seqs_to_file()

if blast.have_blast_db() is False:
if blast.is_blast_db_up_to_date() is False:
blast.create_blast_db()
else:
if blast.is_blast_db_up_to_date() is False:
blast.create_blast_db()

blast.save_query_to_file()
blast.do_blast()
Expand Down
5 changes: 1 addition & 4 deletions voseq/blast_local_full/views.py
Original file line number Diff line number Diff line change
Expand Up @@ -7,11 +7,8 @@ def index(request, voucher_code, gene_code):
blast = BLASTFull('full', voucher_code, gene_code)
blast.save_seqs_to_file()

if blast.have_blast_db() is False:
if blast.is_blast_db_up_to_date() is False:
blast.create_blast_db()
else:
if blast.is_blast_db_up_to_date() is False:
blast.create_blast_db()

blast.save_query_to_file()
blast.do_blast()
Expand Down

0 comments on commit 2a2ddf7

Please sign in to comment.