@@ -159,7 +159,6 @@ export interface DirectoryItemSelectorProps extends TreeViewFinderProps {
159
159
itemFilter ?: ( val : ElementAttributes ) => boolean ;
160
160
expanded ?: UUID [ ] ;
161
161
selected ?: UUID [ ] ;
162
- fetchMetaData ?: boolean ;
163
162
}
164
163
165
164
function sortHandlingDirectories ( a : TreeViewFinderNodeProps , b : TreeViewFinderNodeProps ) : number {
@@ -181,7 +180,6 @@ export function DirectoryItemSelector({
181
180
expanded,
182
181
selected,
183
182
onClose,
184
- fetchMetaData,
185
183
...otherTreeViewFinderProps
186
184
} : Readonly < DirectoryItemSelectorProps > ) {
187
185
const [ data , setData ] = useState < TreeViewFinderNodeProps [ ] > ( [ ] ) ;
@@ -270,10 +268,7 @@ export function DirectoryItemSelector({
270
268
contentFilter ( ) . has ( item . type )
271
269
) ;
272
270
273
- if (
274
- childrenMatchedTypes . length > 0 &&
275
- ( ( equipmentTypes && equipmentTypes . length > 0 ) || fetchMetaData )
276
- ) {
271
+ if ( childrenMatchedTypes . length > 0 && equipmentTypes && equipmentTypes . length > 0 ) {
277
272
return fetchElementsInfos (
278
273
childrenMatchedTypes . map ( ( e : ElementAttributes ) => e . elementUuid ) ,
279
274
types ,
@@ -301,7 +296,7 @@ export function DirectoryItemSelector({
301
296
console . warn ( `Could not update subs (and content) of '${ nodeId } ' : ${ error . message } ` ) ;
302
297
} ) ;
303
298
} ,
304
- [ types , equipmentTypes , fetchMetaData , contentFilter , itemFilter , addToDirectory ]
299
+ [ types , equipmentTypes , itemFilter , contentFilter , addToDirectory ]
305
300
) ;
306
301
307
302
// Helper function to fetch children for a node if not already loaded
0 commit comments