Browse Source

fix page blank if schema is not ready

Signed-off-by: ryjiang <jiangruiyi@gmail.com>
ryjiang 1 year ago
parent
commit
584a285176
1 changed files with 1 additions and 1 deletions
  1. 1 1
      client/src/pages/collections/StatusAction.tsx

+ 1 - 1
client/src/pages/collections/StatusAction.tsx

@@ -127,7 +127,7 @@ const StatusAction: FC<StatusActionType> = props => {
     }
   }, [status, statusTrans, percentage]);
 
-  const noIndex = !schema.hasVectorIndex;
+  const noIndex = schema && !schema.hasVectorIndex;
   const noVectorIndexTooltip = collectionTrans('noVectorIndexTooltip');
   const noIndexIcon = (
     <div className={`${classes.circle} ${classes.noIndex}`}></div>