Skip to content

Fixed file extension extraction issue for filenames with multiple dots. #62

New issue

Have a question about this project? # for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “#”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? # to your account

Open
wants to merge 2 commits into
base: main
Choose a base branch
from

Conversation

NimeshaKahingala
Copy link
Collaborator

@NimeshaKahingala NimeshaKahingala commented Mar 7, 2025

Refactored File Extension Extraction

  • Improved file extension extraction to handle filenames with multiple dots dynamically.
  • Instead of checking for fixed extensions (.yml or .json) and slicing based on fixed lengths, the new solution uses lastIndexOf('.') to reliably separate the filename and extension.
  • This improves flexibility by supporting any file extension while preventing incorrect slicing for filenames with multiple dots.

Backend Refactor

  • Moved the file extension splitting logic to the backend to keep the frontend logic cleaner and abstract internal implementation details.

# for free to join this conversation on GitHub. Already have an account? # to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant