diff options
-rw-r--r-- | build/WebpackSPDXPlugin.js | 12 |
1 files changed, 8 insertions, 4 deletions
diff --git a/build/WebpackSPDXPlugin.js b/build/WebpackSPDXPlugin.js index e9eeccca0f1..82ccfabf173 100644 --- a/build/WebpackSPDXPlugin.js +++ b/build/WebpackSPDXPlugin.js @@ -198,8 +198,11 @@ class WebpackSPDXPlugin { authors.add(pkg.author) output += `\n- ${pkg.name}\n\t- version: ${pkg.version}\n\t- license: ${license}` } - output += `\n\nSPDX-License-Identifier: ${[...licenses].sort().join(' AND ')}\n` - output += [...authors].sort().map((author) => `SPDX-FileCopyrightText: ${author}`).join('\n'); + output += '\n\n' + for (const license of [...licenses].sort()) { + output += `SPDX-License-Identifier: ${license}\n` + } + output += [...authors].sort().map((author) => `SPDX-FileCopyrightText: ${author}`).join('\n') compilation.emitAsset( asset.split('?', 2)[0] + '.license', @@ -208,9 +211,10 @@ class WebpackSPDXPlugin { } if (callback) { - return void callback() + return callback() } } + } -module.exports = WebpackSPDXPlugin; +module.exports = WebpackSPDXPlugin |