Commit a7fa3b42 authored by nanahira's avatar nanahira

fix preview

parent 18de85da
......@@ -344,6 +344,10 @@ def route_api_preview():
if not song_id or not re.match('^[0-9]+$', song_id):
abort(400)
song_id = int(song_id)
if not song_id:
abort(400)
song = db.songs.find_one({'id': song_id})
if not song:
abort(400)
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment