* fix(image): Correctly handle query parameters in image URL validation
The imageUrl validator currently fails to correctly extract the file extension
when the image URL contains query parameters or fragments (e.g., 'image.qcow2?token=abc').
This change introduces a dedicated function, `getFilenameFromUrl`,
which uses the native URL object for robust parsing.
This ensures the file suffix validation is always performed on the actual filename,
ignoring any trailing parameters.
Signed-off-by: devsymo <devsymo@hotmail.com>
* fix(lint): Resolve formatting and spacing warnings
Signed-off-by: devsymo <devsymo@hotmail.com>
* fix: adjusted filename extraction logic and remove duplicate code
Signed-off-by: DevSymo <DevSymo@hotmail.com>
---------
Signed-off-by: devsymo <devsymo@hotmail.com>
Signed-off-by: DevSymo <DevSymo@hotmail.com>