User setting modification; general cleanup of Flask app.