Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Ch fix reading stats #104

Merged
merged 1 commit into from
Jun 21, 2019
Merged

Ch fix reading stats #104

merged 1 commit into from
Jun 21, 2019

Conversation

jnkindi
Copy link
Contributor

@jnkindi jnkindi commented Jun 20, 2019

What does this PR do?

  • Adds fields in fetching user reading stats

Description of Task to be completed?

  • This PR will help in listing reading stats details with article read in a specific time

How should this be manually tested?

  • None

Any background context you want to provide?

  • None

updatedAt: singleStat.updatedAt
};
})
);

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Unexpected newline before ')' function-paren-newline

@@ -483,7 +484,22 @@ class User {
if (!stats || stats.length === 0) {
return helper.jsonResponse(res, 404, { message: 'No article read' });
}
return helper.jsonResponse(res, 200, { stats, statsCount: stats.length });
const allStats = await Promise.all(

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Unexpected newline after '(' function-paren-newline

@Inclet Inclet temporarily deployed to strikers-ah-backend-sta-pr-104 June 20, 2019 19:02 Inactive
@jnkindi jnkindi force-pushed the ch-reading-stats-fix-response branch from 4757a7b to 656378b Compare June 20, 2019 20:31
}
}
});
return helper.jsonResponse(res, 200, { statsArticles: allStats, thisWeekRead, thisMonthRead });

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Line 524 exceeds the maximum line length of 100 max-len

updatedAt: singleStat.updatedAt
};
})
);

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Unexpected newline before ')' function-paren-newline

@@ -483,7 +485,43 @@ class User {
if (!stats || stats.length === 0) {
return helper.jsonResponse(res, 404, { message: 'No article read' });
}
return helper.jsonResponse(res, 200, { stats, statsCount: stats.length });
const allStats = await Promise.all(

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Unexpected newline after '(' function-paren-newline

@jnkindi jnkindi merged commit 76d569c into develop Jun 21, 2019
mwibutsa pushed a commit that referenced this pull request Jun 21, 2019
mwibutsa pushed a commit that referenced this pull request Jun 21, 2019
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

5 participants