diff options
author | An-Cheng Huang <ancheng@vyatta.com> | 2010-08-13 18:26:59 -0700 |
---|---|---|
committer | An-Cheng Huang <ancheng@vyatta.com> | 2010-08-13 18:26:59 -0700 |
commit | 9332e5d9d116e313065361cac390048e9524afbf (patch) | |
tree | e4906b6a54794957cb5bc3d622e67fffa7e045a8 /lib/Vyatta | |
parent | 23d52a81e07e829035abc8cfb5f5bf17aaf642a0 (diff) | |
download | vyatta-cfg-9332e5d9d116e313065361cac390048e9524afbf.tar.gz vyatta-cfg-9332e5d9d116e313065361cac390048e9524afbf.zip |
allow Vyatta::Config constructor to set level
Diffstat (limited to 'lib/Vyatta')
-rwxr-xr-x | lib/Vyatta/Config.pm | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/lib/Vyatta/Config.pm b/lib/Vyatta/Config.pm index d37d34f..6dfcc46 100755 --- a/lib/Vyatta/Config.pm +++ b/lib/Vyatta/Config.pm @@ -32,12 +32,13 @@ my %fields = ( ); sub new { - my $that = shift; + my ($that, $level) = @_; my $class = ref ($that) || $that; my $self = { %fields, }; bless $self, $class; + $self->{_level} = $level if defined($level); $self->{_cstore} = new Cstore(); return $self; } |