@lvce-editor/renderer-process 30.71.0 → 30.71.1
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.
|
@@ -785,9 +785,12 @@ const applyDataProperties = (restoredError, error) => {
|
|
|
785
785
|
writable: true
|
|
786
786
|
});
|
|
787
787
|
}
|
|
788
|
-
|
|
789
|
-
|
|
790
|
-
restoredError
|
|
788
|
+
const name = error.data.name || error.data.type;
|
|
789
|
+
if (name) {
|
|
790
|
+
Object.defineProperty(restoredError, 'name', {
|
|
791
|
+
configurable: true,
|
|
792
|
+
value: name
|
|
793
|
+
});
|
|
791
794
|
}
|
|
792
795
|
};
|
|
793
796
|
const applyDirectProperties = (restoredError, error) => {
|
|
@@ -804,7 +807,7 @@ const applyDirectProperties = (restoredError, error) => {
|
|
|
804
807
|
}
|
|
805
808
|
};
|
|
806
809
|
const restoreMessageError = (error, _currentStack) => {
|
|
807
|
-
const restoredError = constructError(error.message, error.type || error.data?.type, error.name);
|
|
810
|
+
const restoredError = constructError(error.message, error.type || error.data?.type, error.name || error.data?.name);
|
|
808
811
|
if (typeof error.code === 'string' || typeof error.code === 'number') {
|
|
809
812
|
Object.defineProperty(restoredError, 'code', {
|
|
810
813
|
configurable: true,
|