Skip to content

Commit

Permalink
Revert "Config::JSON stopped providing a BUILDARGS method, so we can'…
Browse files Browse the repository at this point in the history
…t "around" it. subclass new() the old fashioned way and bump the Config::JSON version dep so we know we're getting the non-Moose one."

... fix is bad Moose style and no one can replicate this problem but me; need to look harder for the problem locally

This reverts commit 55aead8.
  • Loading branch information
scottwalters committed Jul 10, 2012
1 parent 55aead8 commit 560e722
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 5 deletions.
9 changes: 5 additions & 4 deletions lib/WebGUI/Config.pm
Expand Up @@ -100,12 +100,13 @@ The filename of the config file to read.
=cut

sub new {
my $package = shift;
around BUILDARGS => sub {
my $orig = shift;
my $class = shift;
my $filename = shift;
$filename = Cwd::realpath(File::Spec->rel2abs($filename, WebGUI::Paths->configBase));
return $package->SUPER::new($filename);
}
return $class->$orig($filename);
};

1;

2 changes: 1 addition & 1 deletion sbin/testEnvironment.pl
Expand Up @@ -111,7 +111,7 @@ BEGIN
checkModule("JSON", 2.12 );
checkModule("JSON::Any", 1.22 );
checkModule("JSON::PP", 0.00 );
checkModule("Config::JSON", 1.5100 );
checkModule("Config::JSON", "1.3.1" );
checkModule("Text::CSV_XS", "0.64" );
checkModule("Net::CIDR::Lite", 0.20 );
checkModule("Finance::Quote", 1.15 );
Expand Down

0 comments on commit 560e722

Please sign in to comment.