projects
/
freeside.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
2ea58ba
)
prevent more duplicate MACs from sneaking in in the interim
author
jeff
<jeff>
Fri, 13 Mar 2009 18:22:21 +0000
(18:22 +0000)
committer
jeff
<jeff>
Fri, 13 Mar 2009 18:22:21 +0000
(18:22 +0000)
FS/FS/svc_broadband.pm
patch
|
blob
|
history
diff --git
a/FS/FS/svc_broadband.pm
b/FS/FS/svc_broadband.pm
index
b808527
..
eb29646
100755
(executable)
--- a/
FS/FS/svc_broadband.pm
+++ b/
FS/FS/svc_broadband.pm
@@
-217,6
+217,10
@@
sub check {
;
return $error if $error;
+ #redundant, but prevents further problems until column constraint in place
+ return "MAC already in use"
+ if scalar( qsearch( 'svc_broadband', { 'mac_addr', $self->mac_addr } ) );
+
if($self->speed_up < 0) { return 'speed_up must be positive'; }
if($self->speed_down < 0) { return 'speed_down must be positive'; }