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

Check if "." before extension in image URL #976

Merged
merged 1 commit into from
Dec 7, 2020

Conversation

processprocess
Copy link
Contributor

@processprocess processprocess commented Dec 7, 2020

Context / Fixes #977

URLs can end with a string in imageExtensions and not be an image. For example:
https://arts.visualstories.com/quizzes/know-your-art-a-trivia-on-renaissance-art

This will check it the url also has an . before the extension.

For a follow up, we should to do something like this for isPathNameAFont too.

@patrickkettner patrickkettner merged commit 174ddbc into ampproject:main Dec 7, 2020
@patrickkettner
Copy link
Collaborator

thanks!

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

Successfully merging this pull request may close these issues.

isPathNameAnImage incorrectly identifies image paths
3 participants