Subject: | warnings when content-encoding is unset |
Using WWW-Contact & Yahoo, I get a warning:
Use of uninitialized value in string eq at /usr/lib/perl5/
site_perl/5.8.5/WWW/Mechanize/GZip.pm line 91.
Fix:
Replace
if ($response && $response->headers->header('content-encoding') eq
'gzip')
with
if ($response && $response->headers->header('content-encoding') &&
$response->headers->header('content-encoding') eq 'gzip')
to ensure $response->headers->header('content-encoding') is defined
before doing eq comparison.