From 4671f21ba969b48a0490457c296d9b585b64c055 Mon Sep 17 00:00:00 2001 From: Bryan Newbold Date: Tue, 2 Apr 2019 15:32:30 -0700 Subject: fix webface changelog; health.json is a pseudo-API --- python/fatcat_web/routes.py | 13 +++++++------ 1 file changed, 7 insertions(+), 6 deletions(-) diff --git a/python/fatcat_web/routes.py b/python/fatcat_web/routes.py index 118f402b..2bfb9025 100644 --- a/python/fatcat_web/routes.py +++ b/python/fatcat_web/routes.py @@ -501,7 +501,8 @@ def editor_editgroups(ident): @app.route('/changelog', methods=['GET']) def changelog_view(): try: - entries = api.get_changelog(limit=request.args.get('limit')) + #limit = int(request.args.get('limit', 10)) + entries = api.get_changelog() except ApiException as ae: abort(ae.status) return render_template('changelog.html', entries=entries) @@ -618,6 +619,11 @@ def release_citeproc(ident): else: return Response(cite, mimetype="text/plain") +@app.route('/health.json', methods=['GET', 'OPTIONS']) +@crossdomain(origin='*',headers=['access-control-allow-origin','Content-Type']) +def health_json(): + return jsonify({'ok': True}) + ### Auth #################################################################### @@ -732,8 +738,3 @@ def fatcat_photo(): return send_from_directory(os.path.join(app.root_path, 'static'), 'fatcat.jpg', mimetype='image/jpeg') - -@app.route('/health', methods=['GET', 'OPTIONS']) -@crossdomain(origin='*',headers=['access-control-allow-origin','Content-Type']) -def health(): - return jsonify({'ok': True}) -- cgit v1.2.3