Allow gold users to see 100 subreddits at once

This commit is contained in:
Jason Harvey
2011-07-21 16:30:00 -07:00
committed by Max Goodman
parent 53740ec4e8
commit eacdfc1d6a

View File

@@ -441,6 +441,11 @@ class Subreddit(Thing, Printable):
# has_subscribed == False by default.
if user and user.has_subscribed:
sr_ids = Subreddit.reverse_subscriber_ids(user)
# Allow the goldies to see more subreddits
if user.gold:
limit = 100
if limit and len(sr_ids) > limit:
sr_ids.sort()
sr_ids = cls.random_reddits(user.name, sr_ids, limit)