Add web front-end and fix API issues
This commit is contained in:
1 parent
45ca4de0ad
commit
a7524412f0
2571 files changed
+86998
-5
No files matched your search
+28
@@ -0,0 +1,28 @@
|
||||
import { config } from '../config';
|
||||
var context = null;
|
||||
export function errorContext(cb) {
|
||||
if (config.useDeprecatedSynchronousErrorHandling) {
|
||||
var isRoot = !context;
|
||||
if (isRoot) {
|
||||
context = { errorThrown: false, error: null };
|
||||
}
|
||||
cb();
|
||||
if (isRoot) {
|
||||
var _a = context, errorThrown = _a.errorThrown, error = _a.error;
|
||||
context = null;
|
||||
if (errorThrown) {
|
||||
throw error;
|
||||
}
|
||||
}
|
||||
}
|
||||
else {
|
||||
cb();
|
||||
}
|
||||
}
|
||||
export function captureError(err) {
|
||||
if (config.useDeprecatedSynchronousErrorHandling && context) {
|
||||
context.errorThrown = true;
|
||||
context.error = err;
|
||||
}
|
||||
}
|
||||
//# sourceMappingURL=errorContext.js.map
|
||||
Reference in new issue
Block a user