From e1fd794ef7e161c94576fdec5946c536de15723d Mon Sep 17 00:00:00 2001 From: Jake Bolam Date: Wed, 7 Sep 2022 04:27:30 -0400 Subject: [PATCH] fix: set default value as `7` for `contributorsPerLine` (#139) fix: set default value as `7` for `contributorsPerLine` Co-authored-by: Maximilian Berkmann Co-authored-by: Angel Aviel Domaoan <13580338+tenshiAMD@users.noreply.github.com> --- src/generate/index.js | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/src/generate/index.js b/src/generate/index.js index b9b7e21..05fb9dd 100644 --- a/src/generate/index.js +++ b/src/generate/index.js @@ -44,6 +44,7 @@ function formatLine(contributors) { } function generateContributorsList(options, contributors) { + const contributorsPerLine = options.contributorsPerLine || 7 return _.flow( _.sortBy(contributor => { if (options.contributorsSortAlphabetically) { @@ -53,7 +54,7 @@ function generateContributorsList(options, contributors) { _.map(function formatEveryContributor(contributor) { return formatContributor(options, contributor) }), - _.chunk(options.contributorsPerLine), + _.chunk(contributorsPerLine), _.map(formatLine), _.join('\n \n \n '), newContent => {