Permalink
Browse files

Merge pull request #2080 from antgonza/fix-private_public-stats-page

fixing private/public studies
  • Loading branch information...
2 parents 53188a6 + 7d70a38 commit 4bf4808b5a8b1d4024f7cef96b1155f8d89f6e26 @josenavas josenavas committed on GitHub Feb 15, 2017
Showing with 6 additions and 6 deletions.
  1. +2 −2 qiita_db/meta_util.py
  2. +4 −4 qiita_db/test/test_meta_util.py
@@ -160,8 +160,8 @@ def update_redis_stats():
artifact filepaths that are not present in the file system
"""
STUDY = qdb.study.Study
- studies = {'public': STUDY.get_by_status('private'),
- 'private': STUDY.get_by_status('public'),
+ studies = {'public': STUDY.get_by_status('public'),
+ 'private': STUDY.get_by_status('private'),
'sanbox': STUDY.get_by_status('sandbox')}
number_studies = {k: len(v) for k, v in viewitems(studies)}
@@ -184,10 +184,10 @@ def test_update_redis_stats(self):
portal = qiita_config.portal
vals = [
- ('number_studies', {'sanbox': '0', 'public': '1',
- 'private': '0'}, r_client.hgetall),
- ('number_of_samples', {'sanbox': '0', 'public': '27',
- 'private': '0'}, r_client.hgetall),
+ ('number_studies', {'sanbox': '0', 'public': '0',
+ 'private': '1'}, r_client.hgetall),
+ ('number_of_samples', {'sanbox': '0', 'public': '0',
+ 'private': '27'}, r_client.hgetall),
('num_users', '4', r_client.get),
('lat_longs', EXP_LAT_LONG, r_client.get),
('num_studies_ebi', '1', r_client.get),

0 comments on commit 4bf4808

Please sign in to comment.