From 698326000340e702ee464d8fafb59ee89fff9cfd Mon Sep 17 00:00:00 2001 From: Simon Lecoq <22963968+lowlighter@users.noreply.github.com> Date: Tue, 29 Jun 2021 19:06:50 +0200 Subject: [PATCH] Update index.mjs --- source/plugins/activity/index.mjs | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/source/plugins/activity/index.mjs b/source/plugins/activity/index.mjs index a31f912e..a3bb6c0a 100644 --- a/source/plugins/activity/index.mjs +++ b/source/plugins/activity/index.mjs @@ -39,7 +39,7 @@ export default async function({login, data, rest, q, account, imports}, {enabled //Extract activity events const activity = (await Promise.all( events - .filter(({actor}) => account === "organization" ? true : actor.login === login) + .filter(({actor}) => account === "organization" ? true : actor.login?.toLocaleLowerCase() === login.toLocaleLowerCase()) .filter(({created_at}) => Number.isFinite(days) ? new Date(created_at) > new Date(Date.now() - days * 24 * 60 * 60 * 1000) : true) .filter(event => visibility === "public" ? event.public : true) .map(async ({type, payload, actor:{login:actor}, repo:{name:repo}, created_at}) => {