Skip to content

Commit 3aa7d30

Browse files
committed
error on empty imodel connection
1 parent 9e58e13 commit 3aa7d30

File tree

1 file changed

+1
-9
lines changed

1 file changed

+1
-9
lines changed

packages/changed-elements-react/src/NamedVersionSelector/NamedVersionSelector.tsx

Lines changed: 1 addition & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -94,7 +94,7 @@ export function NamedVersionSelectorWidget(props: Readonly<NamedVersionSelectorW
9494
}
9595

9696
if (!iModel.iTwinId || !iModel.iModelId || !iModel.changeset.id) {
97-
return <NoNamedVersionsState />;
97+
throw new Error("Empty IModel Connection")
9898
}
9999

100100
const iTwinId = iModel.iTwinId;
@@ -224,14 +224,6 @@ function EmptyState(): ReactElement {
224224
);
225225
}
226226

227-
function NoNamedVersionsState(): ReactElement {
228-
return (
229-
<Text className="_cer_v1_empty-state" isMuted>
230-
{t("VersionCompare:versionCompare.noNamedVersions")}
231-
</Text>
232-
);
233-
}
234-
235227
function LoadingState(): ReactElement {
236228
return (
237229
<LoadingContent>

0 commit comments

Comments
 (0)