Problem/Motivation
If a file has an uppercase extension ( e.g. : cat-picture.JPG / cat-picture.WEBP ) the module will not generate a fallback because it fails to match the Drupal\wpf\ImageFactoryInterface::JPG_PATTERN regex.
Steps to reproduce
1. Upload an image with an uppercase extension.
2. Try to open the fallback.
Expected behavior: display the jpg fallback.
Actual behavior: not found error.
Proposed resolution
Simply need to add an /i option to the regex pattern.
Remaining tasks
N/A
User interface changes
N/A
API changes
N/A
Data model changes
N/A
| Comment | File | Size | Author |
|---|---|---|---|
| #2 | 3516041-2.patch | 714 bytes | adinancenci |
Issue fork wpf-3516041
Show commands
Start within a Git clone of the project using the version control instructions.
Or, if you do not have SSH keys set up on git.drupalcode.org:
Comments
Comment #2
adinancenci commentedHere is how I solved it.
Comment #4
adinancenci commentedComment #6
adinancenci commentedHello. I've raised a merge request with a fix.
Needs review.
Thank you.
Comment #7
adinancenci commentedComment #8
julio_retkwaHi @adinancenci I've just tested this following the steps
1. Upload an image with an uppercase extension.
2. Try to open the fallback.
And is working fine
Thank you!
Comment #9
dj1999 commentedComment #11
dj1999 commentedComment #12
dj1999 commented