mirror of
https://github.com/samuelclay/NewsBlur.git
synced 2025-09-18 21:50:56 +00:00
Adding activate_all classmethod for queued users.
This commit is contained in:
parent
d90607ca6b
commit
a140be5ecb
1 changed files with 10 additions and 0 deletions
|
@ -983,6 +983,16 @@ class RNewUserQueue:
|
|||
|
||||
user.profile.activate_free()
|
||||
|
||||
@classmethod
|
||||
def activate_all(cls):
|
||||
count = cls.user_count()
|
||||
if not count:
|
||||
logging.debug("~FBNo users to activate, sleeping...")
|
||||
return
|
||||
|
||||
for i in range(count):
|
||||
cls.activate_next()
|
||||
|
||||
@classmethod
|
||||
def add_user(cls, user_id):
|
||||
r = redis.Redis(connection_pool=settings.REDIS_FEED_POOL)
|
||||
|
|
Loading…
Add table
Reference in a new issue