From 5a15dfd18ef4e980ff974398f28ebe54a8f65c5d Mon Sep 17 00:00:00 2001 From: Simon Lecoq <22963968+lowlighter@users.noreply.github.com> Date: Wed, 30 Jun 2021 23:01:45 +0200 Subject: [PATCH] Make it case insensitive --- source/plugins/lines/index.mjs | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/source/plugins/lines/index.mjs b/source/plugins/lines/index.mjs index 68eb1d35..d92962b5 100644 --- a/source/plugins/lines/index.mjs +++ b/source/plugins/lines/index.mjs @@ -31,7 +31,7 @@ export default async function({login, data, imports, rest, q, account}, {enabled if (!Array.isArray(repository)) return //Compute editions - const contributors = repository.filter(({author}) => context.mode === "repository" ? true : author?.login === login) + const contributors = repository.filter(({author}) => context.mode === "repository" ? true : author?.login?.toLocaleLowerCase() === login.toLocaleLowerCase()) for (const contributor of contributors) contributor.weeks.forEach(({a, d}) => (lines.added += a, lines.deleted += d)) })