From 0a59332fe3c66dce98fdd13710594923fabf98f6 Mon Sep 17 00:00:00 2001 From: Jules Date: Thu, 25 Jul 2024 18:03:36 +0200 Subject: [PATCH] [types] - fix: ensure non-optional string for content type check - Removed unnecessary optionality of the `contentType` parameter in `isTextExtractionSupportedContentType` function - Enforce the function to always receive a string argument, aligning with supported content types check --- types/src/shared/text_extraction.ts | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/types/src/shared/text_extraction.ts b/types/src/shared/text_extraction.ts index 02866b620e52..aa9e2d13fbd3 100644 --- a/types/src/shared/text_extraction.ts +++ b/types/src/shared/text_extraction.ts @@ -212,7 +212,7 @@ export class TextExtraction { } export function isTextExtractionSupportedContentType( - contentType: string | undefined + contentType: string ): contentType is SupportedContentTypes { return supportedContentTypes.includes(contentType as SupportedContentTypes); }