Skip to content
This repository has been archived by the owner on Apr 5, 2022. It is now read-only.

Commit

Permalink
Add /decode endpoint
Browse files Browse the repository at this point in the history
  • Loading branch information
BBaoVanC committed Jan 17, 2021
1 parent 00b2a25 commit 9d9de60
Showing 1 changed file with 6 additions and 0 deletions.
6 changes: 6 additions & 0 deletions imgupload.py
Original file line number Diff line number Diff line change
Expand Up @@ -59,6 +59,12 @@ def utf8_encode_filename(filename):
def encode(decoded_url):
return utf8_encode_filename(decoded_url)


@app.route("/decode/<encoded_url>", methods = ["GET"])
def decode(encoded_url):
return utf8_decode_filename(encoded_url)


@app.route("/utf8/<encoded_url>", methods = ["GET"])
def utf8(encoded_url):
print("Received /utf8/ request")
Expand Down

0 comments on commit 9d9de60

Please sign in to comment.