Closed proyb6 closed 6 years ago
You should paste what's in the env["HTTP_ACCEPT"]
for test improvement.
Sorry, added env["HTTP_ACCEPT"]
contains:
text/html,application/xhtml+xml,application/xml;q=0.9,image/webp,image/apng,*/*;q=0.8
I've tested webp
which could not match.
if /webp/.match?(env["HTTP_ACCEPT"])
Just discovered a bug when used in comparing against regex?
Did not match, should be match
if /jpg/.match?(env["HTTP_ACCEPT"])
Working, match as expected
if /jpg/.match(env["HTTP_ACCEPT"])