Skip to content

Commit

Permalink
add time lock period to info route
Browse files Browse the repository at this point in the history
  • Loading branch information
Giacomo Licari committed Mar 25, 2024
1 parent 98c1b94 commit 08af983
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 2 deletions.
4 changes: 3 additions & 1 deletion api/api/routes.py
Original file line number Diff line number Diff line change
Expand Up @@ -17,12 +17,14 @@ def status():
@apiv1.route("/info")
def info():
enabled_tokens = Token.enabled_tokens()
rate_limit_days = current_app.config['FAUCET_RATE_LIMIT_TIME_LIMIT_SECONDS'] / (24*60*60)
enabled_tokens_json = [
{
'address': t.address,
'name': t.name,
'maximumAmount': t.max_amount_day,
'type': t.type
'type': t.type,
'rateLimitDays': round(rate_limit_days, 2)
} for t in enabled_tokens
]
return jsonify(
Expand Down
1 change: 0 additions & 1 deletion api/api/services/validator.py
Original file line number Diff line number Diff line change
@@ -1,5 +1,4 @@
import datetime
import pdb

from flask import current_app, request
from web3 import Web3
Expand Down

0 comments on commit 08af983

Please sign in to comment.