Merge pull request 'Sorting by active monthly desc.' (#6) from sort_active_monthly into main

Reviewed-on: https://yerbamate.ml/LemmyNet/lemmy-stats-crawler/pulls/6
This commit is contained in:
nutomic 2021-04-27 13:10:47 +00:00
commit fefd708777

View file

@ -45,6 +45,10 @@ pub async fn crawl(
} }
} }
// Sort by active monthly users descending
instance_details.sort_by_key(|i| i.users_active_month);
instance_details.reverse();
Ok((instance_details, failed_instances)) Ok((instance_details, failed_instances))
} }