Remove unused polls code to reduce query volume.

Due to use of Submission.{choices, options, bet_options} in realbody,
generating submission_listings resulted in extremely high volume of
SELECT queries.

In local testing with 6 posts, one of which had a poll with 2 options,
the removal of these calls reduced quantity of queries on the homepage
from 84 to 22.

Given that it was previously decided to remove the polls feature after
a regression while adding comment filtering, the remaining dead code
paths for polls were also removed.
This commit is contained in:
TLSM 2022-09-05 03:53:25 -04:00 committed by Ben Rog-Wilhelm
parent cf9819ca5b
commit dbaf0a1bfd
10 changed files with 8 additions and 359 deletions

View file

@ -224,11 +224,6 @@ ACTIONTYPES = {
"icon": 'fa-crown',
"color": 'bg-success'
},
'distribute': {
"str": 'distributed bet winnings to voters on {self.target_link}',
"icon": 'fa-dollar-sign',
"color": 'bg-success'
},
'dump_cache': {
"str": 'dumped cache',
"icon": 'fa-trash-alt',