While perusing the StackExchange JS global object, I noticed StackExchange.options.site.negativeVoteScoreFloor. From searching the Internet Archive, it seems to have appeared some time around October 2019. I don't see anything that looks related when I put is:q created:2019 [score] in MSE's search bar. I'm guessing it's something that was part of an experiment that didn't get used? I don't really have a purpose for asking, since I've never heard of there being a negative vote score floor being implemented. I'm just asking to satisfy my own curiosity.
Add a comment |
1 Answer
It was part of an experiment that never graduated out of beta, based on code comments:
// TODO: This was written for an experiment that did not graduate and can be removed. function normalizePostScore(score) { const negativeVoteScoreFloor = _Shared_options_mod__WEBPACK_IMPORTED_MODULE_1__["default"].site.negativeVoteScoreFloor; return negativeVoteScoreFloor === null ? score : Math.max(negativeVoteScoreFloor, score); } - 2Was is the clamp negative scores to zero experiment?NoDataDumpNoContribution– NoDataDumpNoContribution2024-12-21 14:10:34 +00:00Commented Dec 21, 2024 at 14:10
- @NoDataDumpNoContribution most likely, yes. Can't see any reason it would be something else.user152859– user1528592024-12-22 09:04:32 +00:00Commented Dec 22, 2024 at 9:04
- I suspect this code may also be being used for election primaries, where a nomination's score will be shown as 0 if it's negative. Not sure if the same logic is re-implemented for that.Sonic the Anonymous Hedgehog– Sonic the Anonymous Hedgehog2025-01-04 23:41:19 +00:00Commented Jan 4 at 23:41