Skip to content
New issue

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

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

Already on GitHub? Sign in to your account

Enhance YouTube URL Parsing and Add Unit Tests for Various URL Formats #197

Merged
merged 1 commit into from
Oct 15, 2024

Conversation

irebussoft
Copy link
Contributor

This pull request introduces an enhancement to the YouTube URL parsing method parseVidFromURL() to support multiple YouTube URL formats. The updated functionality now handles:

Full YouTube URLs (e.g., www.youtube.com)
Shortened URLs (e.g., youtu.be)
Embed URLs (e.g., /embed/)
Live stream URLs (e.g., /live/)
Standard video watch URLs (e.g., watch?v=)
Additional variants such as /v/ URLs and URLs with time parameters

In addition to expanding the parsing capabilities, unit tests have been added to validate the behavior across all supported URL types.

Copy link

@akoevroman akoevroman left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

It seems that changes work.

@alaouy alaouy merged commit 07dffec into alaouy:master Oct 15, 2024
@alaouy
Copy link
Owner

alaouy commented Oct 15, 2024

@irebussoft Nicely done, thank you guys for the contribution 🚀

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

Successfully merging this pull request may close these issues.

4 participants