Browse Source

修改bug

yjp 11 months ago
parent
commit
212e352ee8
1 changed files with 4 additions and 1 deletions
  1. 4 1
      sql/parse_table_row.go

+ 4 - 1
sql/parse_table_row.go

@@ -190,7 +190,10 @@ func formOutputEntity(tableRow map[string]any, outputEntity any) error {
 					return errors.New("slice仅支持[]string")
 				}
 
-				strValue := tableRowValue.(string)
+				strValue, ok := tableRowValue.(string)
+				if !ok {
+					return errors.New("slice仅支持[]string")
+				}
 
 				strParts := strings.Split(strValue, element.SplitWith)
 				if strParts == nil || len(strParts) == 0 {