diff options
author | levinse <levinse> | 2011-07-01 06:54:03 +0000 |
---|---|---|
committer | levinse <levinse> | 2011-07-01 06:54:03 +0000 |
commit | 4665d5af02f915679207a369222472a25e137c9d (patch) | |
tree | a86cb48ebf58eca185e4200ae5a89dc340e32429 /FS/FS/svc_acct.pm | |
parent | 4b80fe118da16b21603fcdbd090bc03d8fbf0578 (diff) |
RADIUS group enhancements, overlimit_groups changes, etc. RT13432
Diffstat (limited to 'FS/FS/svc_acct.pm')
-rw-r--r-- | FS/FS/svc_acct.pm | 11 |
1 files changed, 5 insertions, 6 deletions
diff --git a/FS/FS/svc_acct.pm b/FS/FS/svc_acct.pm index e8c797a..7ef8ed3 100644 --- a/FS/FS/svc_acct.pm +++ b/FS/FS/svc_acct.pm @@ -2227,20 +2227,19 @@ sub _op_overlimit { my $cust_pkg = $self->cust_svc->cust_pkg; - my $conf_overlimit = + my @conf_overlimit = $cust_pkg ? $conf->config('overlimit_groups', $cust_pkg->cust_main->agentnum ) : $conf->config('overlimit_groups'); foreach my $part_export ( $self->cust_svc->part_svc->part_export ) { - my $groups = $conf_overlimit || $part_export->option('overlimit_groups'); - next unless $groups; - - my $gref = &{ $self->_fieldhandlers->{'usergroup'} }( $self, $groups ); + my @groups = scalar(@conf_overlimit) ? @conf_overlimit + : split(' ',$part_export->option('overlimit_groups')); + next unless scalar(@groups); my $other = new FS::svc_acct $self->hashref; - $other->usergroup( $gref ); + $other->usergroup(\@groups); my($new,$old); if ($action eq 'suspend') { |