From 79ed7224ebf48f0f9392043db8d37b33696d3332 Mon Sep 17 00:00:00 2001 From: Salman Date: Wed, 18 Nov 2020 18:20:44 +0530 Subject: [PATCH] chore: use log helper for info --- src/index.js | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/src/index.js b/src/index.js index ddfe0055..265d1d25 100644 --- a/src/index.js +++ b/src/index.js @@ -1,6 +1,7 @@ const core = require('@actions/core') const github = require('@actions/github') +const { logInfo } = require('./log') const { getInputs } = require('./util') const { GITHUB_TOKEN, MERGE_METHOD, EXCLUDE_PKGS } = getInputs() @@ -17,14 +18,14 @@ async function run () { const isDependabotPR = pr.user.login === 'dependabot[bot]' if (!isDependabotPR) { - return core.info('Not dependabot PR, skip merging.') + return logInfo('Not dependabot PR, skip merging.') } // dependabot branch names are in format "dependabot/npm_and_yarn/pkg-0.0.1" const pkgName = pr.head.ref.split('/').pop().split('-').shift() if (EXCLUDE_PKGS.includes(pkgName)) { - return core.info(`${pkgName} is excluded, skip merging.`) + return logInfo(`${pkgName} is excluded, skip merging.`) } await octokit.pulls.createReview({