@candlerip/shared3 0.0.124 → 0.0.125
Sign up to get free protection for your applications and to get access to all the features.
package/package.json
CHANGED
@@ -4,15 +4,21 @@ export const customErrorWorker = (info) => {
|
|
4
4
|
let _info = info;
|
5
5
|
let _projectName;
|
6
6
|
const addInfo = (info) => {
|
7
|
+
composeInfo(info);
|
8
|
+
};
|
9
|
+
const composeCustomError = (message, info) => {
|
10
|
+
composeInfo(info);
|
11
|
+
return composeCustomErrorFunc(message, _projectName ?? ProjectSingleton.getProjectName(), _info);
|
12
|
+
};
|
13
|
+
const composeInfo = (info) => {
|
14
|
+
if (!_info && !info) {
|
15
|
+
return;
|
16
|
+
}
|
7
17
|
_info = {
|
8
18
|
..._info,
|
9
19
|
...info,
|
10
20
|
};
|
11
21
|
};
|
12
|
-
const composeCustomError = (message, info) => composeCustomErrorFunc(message, _projectName ?? ProjectSingleton.getProjectName(), {
|
13
|
-
..._info,
|
14
|
-
...info,
|
15
|
-
});
|
16
22
|
const setProjectName = (projectName) => {
|
17
23
|
_projectName = projectName;
|
18
24
|
};
|