3 ms·
Nope, because the old one's already been pushed off the end of the list and it doesn't re-generate the list when you unsave, just removes the item from the list
by Deimorz 8y ago
Nope, because the old one's already been pushed off the end of the list and it doesn't re-generate the list when you unsave, just removes the item from the list.
Imagine I have a list of max length 5, when I initially fill it up it looks like [5, 4, 3, 2, 1]. If I save one more thing, it adds 6 at the front, then truncates the list and removes the 1 from the end, so now you have [6, 5, 4, 3, 2]. At that point, if I unsave #3, it just removes it from the list so you'd have [6, 5, 4, 2]. #1 is still saved, but nothing happens to pull it back into the list.
- rotred 8y agowhy would they make the limit so low?
- Deimorz 8y agoNot sure, the 1000 limit is in the file from its very first version 10 years ago: https://github.com/reddit-archive/reddit/commit/33fd4e9684ca7668b57aa32ab6a064cd2a86ef6d#diff-8e12a829341215de40b3890544842ed0R14 https://github.com/reddit-archive/reddit/commit/33fd4e9684ca... 1000 probably seemed like a lot at the time or had reasonable performance, and it's just never been changed.
- ralfd 8y agoWhat if you unsave 2 items and save 1. Is then the list remade?
- Deimorz 8y agoNo, the list is never remade. The new item just gets inserted into the list, exactly the same as if it had never reached the limit in the first place.