Skip to content

Commit 84beb67

Browse files
committed
fix: fix error in automatic merge
1 parent 0b0567a commit 84beb67

File tree

2 files changed

+4
-4
lines changed

2 files changed

+4
-4
lines changed

src/fetchers/stats-fetcher.js

+3-3
Original file line numberDiff line numberDiff line change
@@ -70,7 +70,7 @@ const GRAPHQL_STATS_QUERY = `
7070
*
7171
* @param {import('axios').AxiosRequestHeaders} variables Fetcher variables.
7272
* @param {string} token GitHub token.
73-
* @returns {Promise<Object>} Stats fetcher response.
73+
* @returns {Promise<import('../common/types').Fetcher>} Stats fetcher response.
7474
*/
7575
const fetcher = (variables, token) => {
7676
const query = !variables.after ? GRAPHQL_STATS_QUERY : GRAPHQL_REPOS_QUERY;
@@ -89,7 +89,7 @@ const fetcher = (variables, token) => {
8989
* Fetch stats information for a given username.
9090
*
9191
* @param {string} username Github username.
92-
* @returns {Promise<Object>} GraphQL Stats object.
92+
* @returns {Promise<import('../common/types').StatsFetcher>} GraphQL Stats object.
9393
*
9494
* @description This function supports multi-page fetching if the 'FETCH_MULTI_PAGE_STARS' environment variable is set to true.
9595
*/
@@ -256,7 +256,7 @@ const fetchStats = async (
256256
return prev + curr.stargazers.totalCount;
257257
}, 0);
258258

259-
// @ts-ignore
259+
// @ts-ignore // TODO: Fix this.
260260
stats.rank = calculateRank({
261261
totalCommits: stats.totalCommits,
262262
totalRepos: user.repositories.totalCount,

tests/api.test.js

+1-1
Original file line numberDiff line numberDiff line change
@@ -275,7 +275,7 @@ describe("Test /api/", () => {
275275
text_color: "fff",
276276
bg_color: "fff",
277277
},
278-
data,
278+
data_stats,
279279
);
280280

281281
await api(req, res);

0 commit comments

Comments
 (0)