@gravity-ui/app-builder 0.11.2 → 0.11.3
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
|
@@ -73,13 +73,15 @@ const pitch = function (request) {
|
|
|
73
73
|
configureSourceMap(workerCompiler);
|
|
74
74
|
const cb = this.async();
|
|
75
75
|
workerCompiler.compile((err, compilation) => {
|
|
76
|
-
if (
|
|
77
|
-
|
|
76
|
+
if (compilation) {
|
|
77
|
+
workerCompiler.parentCompilation?.children.push(compilation);
|
|
78
78
|
}
|
|
79
|
-
workerCompiler.parentCompilation?.children.push(compilation);
|
|
80
79
|
if (err) {
|
|
81
80
|
return cb(err);
|
|
82
81
|
}
|
|
82
|
+
if (!compilation) {
|
|
83
|
+
return cb(new Error('Child compilation failed'));
|
|
84
|
+
}
|
|
83
85
|
if (compilation.errors && compilation.errors.length) {
|
|
84
86
|
const errorDetails = compilation.errors
|
|
85
87
|
.map((error) => {
|
|
@@ -95,7 +97,7 @@ const pitch = function (request) {
|
|
|
95
97
|
const cacheIdent = request;
|
|
96
98
|
const objectToHash = compilation.assets[filename];
|
|
97
99
|
if (!objectToHash) {
|
|
98
|
-
|
|
100
|
+
return cb(new Error(`Asset ${filename} not found in compilation`));
|
|
99
101
|
}
|
|
100
102
|
const cacheETag = cache.getLazyHashedEtag(objectToHash);
|
|
101
103
|
return cache.get(cacheIdent, cacheETag, (getCacheError, cacheContent) => {
|