|
@@ -186,5 +186,6 @@ class db():
|
|
|
#matches, kw, weight
|
|
#matches, kw, weight
|
|
|
|
|
|
|
|
def get_sources_with_error(self):
|
|
def get_sources_with_error(self):
|
|
|
- self.c_articles.aggregate([{'$match': {'error': True}},
|
|
|
|
|
- {'$group': {'_id': '$source_name', 'count': {'$sum': 1}}}])
|
|
|
|
|
|
|
+ r = self.c_articles.aggregate([{'$match': {'error': True}},
|
|
|
|
|
+ {'$group': {'_id': '$source_name', 'count': {'$sum': 1}}}])
|
|
|
|
|
+ return r
|