fix(typo): acient -> ancient

This commit is contained in:
Milesq 2020-12-31 17:29:26 +01:00
parent 86d3e8e13f
commit 82f374cbe2
2 changed files with 4 additions and 4 deletions

View file

@ -49,7 +49,7 @@ export class Card {
trophyList.push(
new MultipleLangTrophy(userInfo.languageCount),
new LongTimeAccountTrophy(userInfo.durationYear),
new AncientAccountTrophy(userInfo.acientAccount),
new AncientAccountTrophy(userInfo.ancientAccount),
new Joined2020Trophy(userInfo.joined2020),
new AllSuperRankTrophy(isAllSRank),
);

View file

@ -9,7 +9,7 @@ export class UserInfo {
public totalRepositories: number,
public languageCount: number,
public durationYear: number,
public acientAccount: number,
public ancientAccount: number,
public joined2020: number,
) {
}
@ -92,7 +92,7 @@ export class GithubAPIClient {
const durationTime = new Date().getTime() -
new Date(userData.createdAt).getTime();
const durationYear = new Date(durationTime).getUTCFullYear() - 1970;
const acientAccount = new Date(userData.createdAt).getFullYear() <= 2010
const ancientAccount = new Date(userData.createdAt).getFullYear() <= 2010
? 1
: 0;
const joined2020 = new Date(userData.createdAt).getFullYear() == 2020
@ -107,7 +107,7 @@ export class GithubAPIClient {
userData.repositories.totalCount,
languages.size,
durationYear,
acientAccount,
ancientAccount,
joined2020
);
return userInfo;