Skip to content

Commit

Permalink
Removed trailing slashes of endpoints
Browse files Browse the repository at this point in the history
  • Loading branch information
BasMonkey committed Feb 23, 2024
1 parent 057fb5e commit 6f58338
Showing 1 changed file with 4 additions and 4 deletions.
8 changes: 4 additions & 4 deletions ExonCov/api_views.py
Original file line number Diff line number Diff line change
Expand Up @@ -44,7 +44,7 @@ def sample_by_id_api(sample_id):
return jsonify(result)


@app.route('/api/samples/')
@app.route('/api/samples')
@token_required
def get_samples_api():
sample_name = request.args.get('sample_name') or ''
Expand All @@ -63,7 +63,7 @@ def get_samples_api():
return jsonify(samples_list)


@app.route('/api/sample/<sample_name>/run/<run_id>/')
@app.route('/api/sample/<sample_name>/run/<run_id>')
@token_required
def get_summary_by_sample_name_and_run_id_api(sample_name, run_id):
samples = get_samples_by_like_sample_name_or_like_run_id(sample_name, run_id)
Expand All @@ -73,14 +73,14 @@ def get_summary_by_sample_name_and_run_id_api(sample_name, run_id):
return jsonify(samples_list)


@app.route('/api/samples/name/<sample_name>/')
@app.route('/api/samples/name/<sample_name>')
@token_required
def get_sample_by_sample_name_api(sample_name):
sample = get_sample_by_sample_name(sample_name)
return jsonify(model_to_dict(sample))


@app.route('/api/sample/run/<run_id>/')
@app.route('/api/sample/run/<run_id>')
@token_required
def get_summary_by_run_id_api(run_id):
samples = get_sample_by_like_run_id(run_id)
Expand Down

0 comments on commit 6f58338

Please sign in to comment.