mirror of
https://github.com/Redocly/redoc.git
synced 2025-07-11 00:32:36 +03:00
fix: call onLoaded if specs are not found (#2182)
This commit is contained in:
parent
187e555558
commit
0753bbea4b
|
@ -48,6 +48,9 @@ export function StoreBuilder(props: StoreBuilderProps) {
|
||||||
const resolved = await loadAndBundleSpec(spec || specUrl!);
|
const resolved = await loadAndBundleSpec(spec || specUrl!);
|
||||||
setResolvedSpec(resolved);
|
setResolvedSpec(resolved);
|
||||||
} catch (e) {
|
} catch (e) {
|
||||||
|
if (onLoaded) {
|
||||||
|
onLoaded(e);
|
||||||
|
}
|
||||||
setError(e);
|
setError(e);
|
||||||
throw e;
|
throw e;
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in New Issue
Block a user