mirror of
https://github.com/viq/NewsBlur.git
synced 2025-08-05 16:49:45 +00:00
Adding user count to notifications tester.
This commit is contained in:
parent
c9649abce0
commit
2597f83ae2
2 changed files with 3 additions and 3 deletions
|
@ -158,7 +158,7 @@ class MUserFeedNotification(mongo.Document):
|
||||||
if sent:
|
if sent:
|
||||||
sent_count += 1
|
sent_count += 1
|
||||||
total_sent_count += 1
|
total_sent_count += 1
|
||||||
return total_sent_count
|
return total_sent_count, len(notifications)
|
||||||
|
|
||||||
def classifiers(self, usersub):
|
def classifiers(self, usersub):
|
||||||
classifiers = {}
|
classifiers = {}
|
||||||
|
|
|
@ -95,6 +95,6 @@ def force_push(request):
|
||||||
count = request.REQUEST.get('count', 1)
|
count = request.REQUEST.get('count', 1)
|
||||||
|
|
||||||
logging.user(user, "~BM~FWForce pushing %s stories: ~SB%s" % (count, Feed.get_by_id(feed_id)))
|
logging.user(user, "~BM~FWForce pushing %s stories: ~SB%s" % (count, Feed.get_by_id(feed_id)))
|
||||||
sent_count = MUserFeedNotification.push_feed_notifications(feed_id, new_stories=count, force=True)
|
sent_count, user_count = MUserFeedNotification.push_feed_notifications(feed_id, new_stories=count, force=True)
|
||||||
|
|
||||||
return {"message": "Pushed %s notifications" % sent_count}
|
return {"message": "Pushed %s notifications to %s users" % (sent_count, user_count)}
|
Loading…
Add table
Reference in a new issue