diff options
author | Simon McVittie <smcv@debian.org> | 2019-02-10 16:29:19 +0000 |
---|---|---|
committer | Simon McVittie <smcv@debian.org> | 2019-02-24 18:49:58 +0000 |
commit | e7b0d4a0fff8ed45a90c2efe8ef294bdf7c9bdac (patch) | |
tree | 88c59b93131682ee847d35b7a7bbca9f5f7f8cd0 /IkiWiki.pm | |
parent | 824cf7db1b96a16b080e284bc3ebf90c1f14a203 (diff) | |
download | ikiwiki-e7b0d4a0fff8ed45a90c2efe8ef294bdf7c9bdac.tar ikiwiki-e7b0d4a0fff8ed45a90c2efe8ef294bdf7c9bdac.tar.gz |
useragent: Raise an exception if the LWP module can't be loaded
Signed-off-by: Simon McVittie <smcv@debian.org>
Diffstat (limited to 'IkiWiki.pm')
-rw-r--r-- | IkiWiki.pm | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/IkiWiki.pm b/IkiWiki.pm index 90cb96e58..dc047b08a 100644 --- a/IkiWiki.pm +++ b/IkiWiki.pm @@ -2470,6 +2470,9 @@ sub add_autofile ($$$) { } sub useragent () { + eval q{use LWP}; + error($@) if $@; + return LWP::UserAgent->new( cookie_jar => $config{cookiejar}, env_proxy => 1, # respect proxy env vars |