Skip to main content

encodedImageExtentionCheck

talawa-apiDocs


talawa-api / utilities/encodedImageStorage/encodedImageExtensionCheck / encodedImageExtentionCheck

Function: encodedImageExtentionCheck()

> encodedImageExtentionCheck(encodedUrl): boolean

Checks if the extension of an encoded image URL is valid (png, jpg, jpeg).

Parameters

encodedUrl: string

Encoded URL of the image.

Returns

boolean

true if the extension is valid, otherwise false.

Defined in

src/utilities/encodedImageStorage/encodedImageExtensionCheck.ts:6