MCPcopy
hub / github.com/simstudioai/sim / isSupportedFileType

Function isSupportedFileType

apps/sim/lib/file-parsers/index.ts:212–219  ·  view source on GitHub ↗
(extension: string)

Source from the content-addressed store, hash-verified

210 * @returns true if supported, false otherwise
211 */
212export function isSupportedFileType(extension: string): extension is SupportedFileType {
213 try {
214 return Object.keys(getParserInstances()).includes(extension.toLowerCase())
215 } catch (error) {
216 logger.error('Error checking supported file type:', error)
217 return false
218 }
219}
220
221export type { FileParseResult, SupportedFileType }

Callers 5

index.test.tsFile · 0.90
handleExternalUrlFunction · 0.90
handleCloudFileFunction · 0.90
handleGenericTextBufferFunction · 0.90

Calls 2

getParserInstancesFunction · 0.85
errorMethod · 0.80

Tested by

no test coverage detected