File tree Expand file tree Collapse file tree 1 file changed +11
-12
lines changed
Expand file tree Collapse file tree 1 file changed +11
-12
lines changed Original file line number Diff line number Diff line change @@ -95,16 +95,15 @@ export function generateSchemaFromItems(
9595 arrays : { mode : arrayMode } ,
9696 } ) as JsonSchemaArray ;
9797 return schema ;
98- } catch {
99- // Fallback: try with simpler approach
100- try {
101- const fallbackSchema = toJsonSchema ( processedItems , {
102- arrays : { mode : 'first' } ,
103- } ) as JsonSchemaArray ;
104- return fallbackSchema ;
105- } catch {
106- // If all attempts fail, return null
107- return null ;
108- }
109- }
98+ } catch { /* ignore */ }
99+
100+ try {
101+ const fallbackSchema = toJsonSchema ( processedItems , {
102+ arrays : { mode : 'first' } ,
103+ } ) as JsonSchemaArray ;
104+ return fallbackSchema ;
105+ } catch { /* ignore */ }
106+
107+ // If all attempts fail, return null
108+ return null ;
110109}
You can’t perform that action at this time.
0 commit comments