mirror of
https://github.com/anuraghazra/github-readme-stats.git
synced 2025-02-05 14:13:31 +08:00
Fixed todo inside stats card data fetcher (#2649)
This commit is contained in:
parent
a82a617a37
commit
31d1ab43d0
@ -29,13 +29,14 @@ const normalcdf = (mean, sigma, to) => {
|
||||
/**
|
||||
* Calculates the users rank.
|
||||
*
|
||||
* @param {number} totalRepos Total number of repos.
|
||||
* @param {number} totalCommits Total number of commits.
|
||||
* @param {number} contributions The number of contributions.
|
||||
* @param {number} followers The number of followers.
|
||||
* @param {number} prs The number of pull requests.
|
||||
* @param {number} issues The number of issues.
|
||||
* @param {number} stargazers The number of stars.
|
||||
* @param {object} params Parameters on which the user's rank depends.
|
||||
* @param {number} params.totalRepos Total number of repos.
|
||||
* @param {number} params.totalCommits Total number of commits.
|
||||
* @param {number} params.contributions The number of contributions.
|
||||
* @param {number} params.followers The number of followers.
|
||||
* @param {number} params.prs The number of pull requests.
|
||||
* @param {number} params.issues The number of issues.
|
||||
* @param {number} params.stargazers The number of stars.
|
||||
* @returns {{level: string, score: number}}} The users rank.
|
||||
*/
|
||||
const calculateRank = ({
|
||||
|
@ -259,7 +259,6 @@ const fetchStats = async (
|
||||
return prev + curr.stargazers.totalCount;
|
||||
}, 0);
|
||||
|
||||
// @ts-ignore // TODO: Fix this.
|
||||
stats.rank = calculateRank({
|
||||
totalCommits: stats.totalCommits,
|
||||
totalRepos: user.repositories.totalCount,
|
||||
|
Loading…
Reference in New Issue
Block a user