fix: change data types in fileSystem to avoid crashing during building process

main
Josue 4 years ago committed by Tsu-ba-me
parent cbad6a52a0
commit 341a4ad50a
  1. 4
      striker-ui/components/FileSystem/FileSystems.tsx
  2. 2
      striker-ui/components/FileSystem/FileSystemsHost.tsx

@ -37,7 +37,7 @@ const SharedStorage = ({ anvil }: { anvil: AnvilListItem[] }): JSX.Element => {
<Box className={classes.root}> <Box className={classes.root}>
{data?.file_systems && {data?.file_systems &&
data.file_systems.map( data.file_systems.map(
(fs: AnvilSharedStorageFileSystem): JSX.Element => ( (fs: AnvilFileSystem): JSX.Element => (
<InnerPanel key={fs.mount_point}> <InnerPanel key={fs.mount_point}>
<PanelHeader> <PanelHeader>
<Box display="flex" width="100%" className={classes.header}> <Box display="flex" width="100%" className={classes.header}>
@ -49,7 +49,7 @@ const SharedStorage = ({ anvil }: { anvil: AnvilListItem[] }): JSX.Element => {
{fs?.hosts && {fs?.hosts &&
fs.hosts.map( fs.hosts.map(
( (
host: AnvilSharedStorageHost, host: AnvilFileSystemHost,
index: number, index: number,
): JSX.Element => ( ): JSX.Element => (
<SharedStorageHost <SharedStorageHost

@ -23,7 +23,7 @@ const useStyles = makeStyles(() => ({
const SharedStorageHost = ({ const SharedStorageHost = ({
host, host,
}: { }: {
host: AnvilSharedStorageHost; host: AnvilFileSystemHost;
}): JSX.Element => { }): JSX.Element => {
const classes = useStyles(); const classes = useStyles();
return ( return (

Loading…
Cancel
Save