Skip to content

Commit 5e83928

Browse files
committed
Do not use new JS syntax
1 parent 55beff2 commit 5e83928

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

scripts/sort-libraries.js

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -92,14 +92,14 @@ const getGitHubStats = async githubRepo => {
9292
average: true,
9393
});
9494
let lastRelease;
95-
if (repo.releases?.nodes?.length) {
95+
if (repo.releases && repo.releases.nodes && repo.releases.nodes.length) {
9696
lastRelease = repo.releases.nodes[0].publishedAt;
9797
}
9898
return {
9999
hasCommitsInLast3Months,
100100
stars,
101101
formattedStars,
102-
license: repo.licenseInfo?.name,
102+
license: repo.licenseInfo && repo.licenseInfo.name,
103103
lastRelease,
104104
formattedLastRelease: lastRelease && timeago.format(lastRelease),
105105
}

0 commit comments

Comments
 (0)