mirror of
https://github.com/donaldzou/WGDashboard.git
synced 2025-10-03 15:56:17 +00:00
Fixed the issue mentioned in #290
This commit is contained in:
@@ -1514,8 +1514,7 @@ def API_addPeers(configName):
|
||||
if (not bulkAdd and (len(public_key) == 0 or len(allowed_ips) == 0)) or len(endpoint_allowed_ip) == 0:
|
||||
return ResponseObject(False, "Please fill in all required box.")
|
||||
if not config.getStatus():
|
||||
return ResponseObject(False,
|
||||
f"{configName} is not running, please turn on the configuration before adding peers.")
|
||||
config.toggleConfiguration()
|
||||
if bulkAdd:
|
||||
if bulkAddAmount < 1:
|
||||
return ResponseObject(False, "Please specify amount of peers you want to add")
|
||||
|
Reference in New Issue
Block a user