mirror of
https://github.com/GNS3/gns3-server
synced 2025-01-24 15:00:57 +00:00
parent
39106ac36b
commit
7e1e63cd09
@ -114,7 +114,10 @@ class ServerHandler:
|
|||||||
def write_settings(request, response):
|
def write_settings(request, response):
|
||||||
controller = Controller.instance()
|
controller = Controller.instance()
|
||||||
controller.settings = request.json
|
controller.settings = request.json
|
||||||
controller.save()
|
try:
|
||||||
|
controller.save()
|
||||||
|
except (OSError, PermissionError) as e:
|
||||||
|
raise HTTPConflict(text="Can't save the settings {}".format(str(e)))
|
||||||
response.json(controller.settings)
|
response.json(controller.settings)
|
||||||
response.set_status(201)
|
response.set_status(201)
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user