Skip to content

Commit 3a97289

Browse files
Merge pull request #648 from dOpensource/bug/646
Fixes #646: Set a default value of 1 for rweight when an endpoint is …
2 parents dd4a481 + 16708e3 commit 3a97289

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

gui/modules/api/carriergroups/functions.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -388,7 +388,7 @@ def addUpdateCarriers(data=None):
388388
hostname = form['hostname'] if len(form['hostname']) > 0 else ''
389389
strip = form['strip'] if len(form['strip']) > 0 else '0'
390390
prefix = form['prefix'] if len(form['prefix']) > 0 else ''
391-
rweight = form['rweight'] if len(form['rweight']) > 0 else 0
391+
rweight = form['rweight'] if 'rweight' in form else 1
392392

393393
if len(hostname) == 0:
394394
raise http_exceptions.BadRequest("Carrier hostname/address is required")

0 commit comments

Comments
 (0)