Automattic / nginx-http-concat

WordPress plugin to perform CSS and JavaScript concatenation of individual script files into one resource request.
GNU General Public License v2.0
115 stars 32 forks source link

Suppressing warnings for gzuncompress #34

Closed emrikol closed 7 years ago

emrikol commented 7 years ago

gzuncompress() will throw a warning with bad data, which can happen from malformed URIs.

p6jPRI-127-p2

mjangda commented 7 years ago

Rather than just suppress the error, we should properly handle things when they fail (since that's a sign that something is broken), e.g. should be exit early instead of executing the rest of the script?

emrikol commented 7 years ago

@mjangda Good idea! I've updated my PR.

I think we still need to suppress the warning, since we can't catch it, nor can we disable it--but we can still check the return value. If you've got other ideas, I'm happy to hear them :)