X-Git-Url: https://git.dogcows.com/gitweb?a=blobdiff_plain;f=lib%2FCGI%2FEx%2FConf.pm;h=872b113ab81c4c2f3ed6a9219cb47baf2304fc1d;hb=0b04f67c06c1db11969096f07dfc7dbb23bf99ba;hp=3af42e552e0d200d6174fbd9dc976ce888d5439b;hpb=ba92ea5b36cbcd9c03016491dfb06dfc74baf409;p=chaz%2Fp5-CGI-Ex diff --git a/lib/CGI/Ex/Conf.pm b/lib/CGI/Ex/Conf.pm index 3af42e5..872b113 100644 --- a/lib/CGI/Ex/Conf.pm +++ b/lib/CGI/Ex/Conf.pm @@ -29,7 +29,7 @@ use vars qw($VERSION ); @EXPORT_OK = qw(conf_read conf_write in_cache); -$VERSION = '2.16'; +$VERSION = '2.23'; $DEFAULT_EXT = 'conf'; @@ -134,7 +134,7 @@ sub conf_read { ### don't die if the file is not found - do die otherwise if (! -e $file) { - eval { die "Conf file $file not found" }; + eval { die "Conf file $file not found\n" }; warn "Conf file $file not found" if ! $args->{'no_warn_on_fail'} && ! $NO_WARN_ON_FAIL; return; } @@ -262,6 +262,7 @@ sub read_handler_json { open (IN, $file) || die "Couldn't open $file: $!"; CORE::read(IN, my $text, -s $file); close IN; + require JSON; return scalar JSON::jsonToObj($text); }