mirror of
https://github.com/FortAwesome/Font-Awesome.git
synced 2025-04-02 14:49:13 +08:00
Update import.macro.js
Fixing an issue where if, `babelMacros` is not set in `package.json`, then there is an error `"config license must be either 'free' or 'pro'"` because `config = {}`. We need to check for the `license` (`config.license`).
This commit is contained in:
parent
65f4bdb502
commit
2c67dae2fa
@ -15,7 +15,7 @@ const styles = [
|
||||
]
|
||||
|
||||
function importer ({references, state, babel, source, config}) {
|
||||
const license = (config !== undefined ? config.license : 'free')
|
||||
const license = ((config !== undefined && config.license !== undefined) ? config.license : 'free')
|
||||
|
||||
if (!['free', 'pro'].includes(license)) {
|
||||
throw new Error(
|
||||
|
Loading…
x
Reference in New Issue
Block a user