Last active
May 25, 2019 03:29
-
-
Save elseagle/8e3431564c309d184c240598e46fcd70 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
@app.route('/item/<string:name>') | |
def get(name): | |
item = find_by_name(name) | |
if item: | |
return item | |
return jsonify({'message': 'Item not found'}), 404 |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment