Changeset - b42ef7e3ca99
[Not reviewed]
dev
0 1 0
Dennis Fink - 9 years ago 2016-05-16 14:27:15
dennis.fink@c3l.lu
Remove RuntimeError except as it isn't raised by onionpy
1 file changed with 0 insertions and 3 deletions:
0 comments (0 inline, 0 general)
ennstatus/api/views.py
Show inline comments
 
@@ -115,27 +115,24 @@ def update():
 
        current_app.logger.warning(' '.join([str(e), str(data)]))
 
        return str(e), 409, {'Content-Type': 'text/plain'}
 

	
 
    try:
 
        server.update_weights()
 
    except NotImplementedError:
 
        pass
 

	
 
    try:
 
        server.update_flags()
 
    except NotImplementedError:
 
        pass
 
    except RuntimeError as e:
 
        current_app.logger.error(str(e), exc_info=True)
 
        pass
 

	
 
    try:
 
        server.save()
 
    except Exception as e:
 
        current_app.logger.error(str(e))
 
        return str(e), 500, {'Content-Type': 'text/plain'}
 

	
 
    current_app.logger.info('Return result')
 
    return (
 
        server.json(), 201,
 
        {
 
            'Location': '/api/export/json/single?server_name={}'.format(
0 comments (0 inline, 0 general)