From 502a2f700328d46d49d97a449870bfc8a60e1914 Mon Sep 17 00:00:00 2001 From: lowlighter <22963968+lowlighter@users.noreply.github.com> Date: Thu, 17 Sep 2020 22:30:16 +0200 Subject: [PATCH] Fix lines plugin --- action/dist/index.js | 4 +--- src/plugins/lines/index.mjs | 4 +--- 2 files changed, 2 insertions(+), 6 deletions(-) diff --git a/action/dist/index.js b/action/dist/index.js index a7364b31..910b40e5 100644 --- a/action/dist/index.js +++ b/action/dist/index.js @@ -9800,10 +9800,8 @@ __webpack_require__.d(__webpack_exports__, { //Compute changed lines response.map(({data:repository}) => { //Check if data are available - if (!repository) + if (!Array.isArray(repository)) return - if (!repository.filter) - console.log(repository.filter, repository) //Extract author const [contributor] = repository.filter(({author}) => author.login === login) //Compute editions diff --git a/src/plugins/lines/index.mjs b/src/plugins/lines/index.mjs index 7973c427..5f11c0c9 100644 --- a/src/plugins/lines/index.mjs +++ b/src/plugins/lines/index.mjs @@ -23,10 +23,8 @@ //Compute changed lines response.map(({data:repository}) => { //Check if data are available - if (!repository) + if (!Array.isArray(repository)) return - if (!repository.filter) - console.log(repository.filter, repository) //Extract author const [contributor] = repository.filter(({author}) => author.login === login) //Compute editions