diff options
author | emkael <emkael@tlen.pl> | 2015-08-28 14:49:52 +0200 |
---|---|---|
committer | emkael <emkael@tlen.pl> | 2015-08-28 14:49:52 +0200 |
commit | 84b22e5ecffb95a84e2a0e9a30f71b127a2cf05e (patch) | |
tree | fca62b51d98f3e5eee68209d2aa0549b7aa6d74b /bidding_data.py | |
parent | a01924e56445e047ed7db503e710c7cb6ff0e716 (diff) |
* omitting link appending when there's no data for a particular score
Diffstat (limited to 'bidding_data.py')
-rw-r--r-- | bidding_data.py | 12 |
1 files changed, 8 insertions, 4 deletions
diff --git a/bidding_data.py b/bidding_data.py index 3107e2f..e845626 100644 --- a/bidding_data.py +++ b/bidding_data.py @@ -259,10 +259,14 @@ class JFRBidding: self.__get_bidding_file_output_path( int(file_number, 10), pair_numbers=pair_numbers)) - # fourth cell is the contract - for link in cells[3].select('a.biddingLink'): - link.extract() - cells[3].append(bidding_link) + # only append link if we've got bidding data + if path.isfile(path.join( + path.dirname(self.__tournament_prefix), + bidding_link['data-bidding-link'])): + # fourth cell is the contract + for link in cells[3].select('a.biddingLink'): + link.extract() + cells[3].append(bidding_link) board_text.seek(0) board_text.write(board_text_content.table.prettify( 'iso-8859-2', formatter='html')) |