Revert "use temp config file for testing"
This reverts commit 9b725c6d42.
This commit is contained in:
parent
ce6f70ca94
commit
6c3369d0cb
22 changed files with 94 additions and 57 deletions
|
|
@ -17,6 +17,7 @@ package WebGUI::Config;
|
|||
use strict;
|
||||
use Class::InsideOut qw(readonly id register);
|
||||
use Cwd ();
|
||||
use File::Spec;
|
||||
use base 'Config::JSON';
|
||||
|
||||
my %config = ();
|
||||
|
|
@ -169,8 +170,10 @@ sub new {
|
|||
my $class = shift;
|
||||
my $webguiPath = Cwd::realpath(shift);
|
||||
my $filename = shift;
|
||||
my $noCache = shift;
|
||||
my $fullPath = Cwd::realpath($webguiPath.'/etc/'.$filename);
|
||||
my $noCache = shift;
|
||||
my $fullPath = File::Spec->file_name_is_absolute($filename)
|
||||
? $filename
|
||||
: Cwd::realpath($webguiPath.'/etc/'.$filename);
|
||||
if ($config{$fullPath}) {
|
||||
return $config{$fullPath};
|
||||
} else {
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue