Skip to content

Commit 28fc626

Browse files
committed
make this a bit nicer
1 parent 2e685ab commit 28fc626

File tree

1 file changed

+2
-4
lines changed

1 file changed

+2
-4
lines changed

site/src/components/TemplateVersionWarnings/TemplateVersionWarnings.tsx

Lines changed: 2 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -8,10 +8,8 @@ export interface TemplateVersionWarningsProps {
88

99
export const TemplateVersionWarnings: FC<
1010
React.PropsWithChildren<TemplateVersionWarningsProps>
11-
> = ({ warnings }) => {
12-
if (!warnings) {
13-
return <></>;
14-
}
11+
> = (props) => {
12+
const { warnings = [] } = props;
1513

1614
if (!warnings.includes("UNSUPPORTED_WORKSPACES")) {
1715
return null;

0 commit comments

Comments
 (0)