diff options
author | Joey Hess <joey@kitenet.net> | 2011-02-25 17:32:36 -0400 |
---|---|---|
committer | Joey Hess <joey@kitenet.net> | 2011-02-25 17:32:36 -0400 |
commit | ecd2153a70882a5a058c20af7e752d656203e13f (patch) | |
tree | d9f9e2dcdc89cf82b536b1edfe8f8c75f184315e /IkiWiki | |
parent | 6982e458c0a905a8b68429290bee01f4b5c02176 (diff) | |
download | ikiwiki-ecd2153a70882a5a058c20af7e752d656203e13f.tar ikiwiki-ecd2153a70882a5a058c20af7e752d656203e13f.tar.gz |
avoid uninitialized value warning when running -dumpsetup
Here wikistatedir has not been configured.
Diffstat (limited to 'IkiWiki')
-rw-r--r-- | IkiWiki/Plugin/transient.pm | 10 |
1 files changed, 6 insertions, 4 deletions
diff --git a/IkiWiki/Plugin/transient.pm b/IkiWiki/Plugin/transient.pm index 9811aa010..c0ad5fc11 100644 --- a/IkiWiki/Plugin/transient.pm +++ b/IkiWiki/Plugin/transient.pm @@ -25,10 +25,12 @@ sub getsetup () { our $transientdir; sub checkconfig () { - $transientdir = $config{wikistatedir}."/transient"; - # add_underlay treats relative underlays as relative to the installed - # location, not the cwd. That's not what we want here. - IkiWiki::add_literal_underlay($transientdir); + if (defined $config{wikistatedir}) { + $transientdir = $config{wikistatedir}."/transient"; + # add_underlay treats relative underlays as relative to the installed + # location, not the cwd. That's not what we want here. + IkiWiki::add_literal_underlay($transientdir); + } } sub change (@) { |