build: fix build script - extractorResult is not defined (#1068)

This commit is contained in:
leex 2020-05-01 02:49:58 +08:00 committed by GitHub
parent 6bb838392d
commit 2e0373bb7a
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -101,12 +101,12 @@ async function build(target) {
const extractorConfig = ExtractorConfig.loadFileAndPrepare(
extractorConfigPath
)
const result = Extractor.invoke(extractorConfig, {
const extractorResult = Extractor.invoke(extractorConfig, {
localBuild: true,
showVerboseMessages: true
})
if (result.succeeded) {
if (extractorResult.succeeded) {
// concat additional d.ts to rolled-up dts (mostly for JSX)
if (pkg.buildOptions && pkg.buildOptions.dts) {
const dtsPath = path.resolve(pkgDir, pkg.types)