Sheet migration check

This commit is contained in:
Cal Corum 2023-09-15 22:38:54 -05:00
parent c29838104a
commit 75bcf10da5

View File

@ -1229,8 +1229,12 @@ class Players(commands.Cog):
return
# Post box score to news-ticker
sc_tab = scorecard.worksheet_by_title('Scorecard')
score_table = sc_tab.get_values('BW8', 'BY9')
try:
sc_tab = scorecard.worksheet_by_title('Scorecard')
score_table = sc_tab.get_values('BW8', 'BY9')
except pygsheets.WorksheetNotFound as e:
sc_tab = scorecard.worksheet_by_title('Box Score')
score_table = sc_tab.get_values('T6', 'B7')
final_inning = all_plays[len(all_plays) - 1][6]
# Log game result