diff --git a/frontend.py b/frontend.py index c6cd084..4a19854 100644 --- a/frontend.py +++ b/frontend.py @@ -40,7 +40,7 @@ limiter = Limiter( @app.route("/add_job", methods=["POST"]) -@limiter.limit("1/second") +@limiter.limit("4/second") def add_job(): req = request.get_json() @@ -90,7 +90,7 @@ def add_job(): @app.route("/cancel_job", methods=["POST"]) -@limiter.limit("1/second") +@limiter.limit("4/second") def cancel_job(): req = request.get_json() if APIKEY not in req: @@ -131,7 +131,7 @@ def cancel_job(): @app.route("/get_jobs", methods=["POST"]) -@limiter.limit("1/second") +@limiter.limit("4/second") def get_jobs(): req = request.get_json() if APIKEY not in req: @@ -168,7 +168,7 @@ def get_jobs(): @app.route("/random_jobs", methods=["GET"]) -@limiter.limit("1/second") +@limiter.limit("4/second") def random_jobs(): # define max number of jobs to fetch from db job_count_limit = 20 diff --git a/templates/index.html b/templates/index.html index 2c111b1..6c17480 100644 --- a/templates/index.html +++ b/templates/index.html @@ -90,7 +90,7 @@ data-zh_CN="非必填。形容这张图不长什么样。">Optional. Describe what's NOT the image.