From 8236514115139ec5d9ee1652c94f1eebe06419da Mon Sep 17 00:00:00 2001 From: Aevann1 Date: Thu, 15 Sep 2022 08:00:03 +0000 Subject: [PATCH] sneed --- files/routes/casino.py | 26 +++++++++++++------------- 1 file changed, 13 insertions(+), 13 deletions(-) diff --git a/files/routes/casino.py b/files/routes/casino.py index 56db1aea7..4cb734054 100644 --- a/files/routes/casino.py +++ b/files/routes/casino.py @@ -13,7 +13,7 @@ from files.helpers.roulette import * @app.get("/casino") @limiter.limit("100/minute;2000/hour;12000/day") -@auth_required +@admin_level_required(3) def casino(v): if v.rehab: return render_template("casino/rehab.html", v=v) @@ -23,7 +23,7 @@ def casino(v): @app.get("/casino/") @limiter.limit("100/minute;2000/hour;12000/day") -@auth_required +@admin_level_required(3) def casino_game_page(v, game): if v.rehab: return render_template("casino/rehab.html", v=v) @@ -42,7 +42,7 @@ def casino_game_page(v, game): @app.get("/casino//feed") @limiter.limit("100/minute;2000/hour;12000/day") -@auth_required +@admin_level_required(3) def casino_game_feed(v, game): if v.rehab: return {"error": "You are under Rehab award effect!"}, 400 @@ -54,7 +54,7 @@ def casino_game_feed(v, game): # Lottershe @app.get("/lottershe") @limiter.limit("100/minute;2000/hour;12000/day") -@auth_required +@admin_level_required(3) def lottershe(v): if v.rehab: return render_template("casino/rehab.html", v=v) @@ -65,7 +65,7 @@ def lottershe(v): # Slots @app.post("/casino/slots") @limiter.limit("100/minute;2000/hour;12000/day") -@auth_required +@admin_level_required(3) def pull_slots(v): if v.rehab: return {"error": "You are under Rehab award effect!"}, 400 @@ -94,7 +94,7 @@ def pull_slots(v): # 21 @app.post("/casino/twentyone/deal") @limiter.limit("100/minute;2000/hour;12000/day") -@auth_required +@admin_level_required(3) def blackjack_deal_to_player(v): if v.rehab: return {"error": "You are under Rehab award effect!"}, 400 @@ -113,7 +113,7 @@ def blackjack_deal_to_player(v): @app.post("/casino/twentyone/hit") @limiter.limit("100/minute;2000/hour;12000/day") -@auth_required +@admin_level_required(3) def blackjack_player_hit(v): if v.rehab: return {"error": "You are under Rehab award effect!"}, 400 @@ -128,7 +128,7 @@ def blackjack_player_hit(v): @app.post("/casino/twentyone/stay") @limiter.limit("100/minute;2000/hour;12000/day") -@auth_required +@admin_level_required(3) def blackjack_player_stay(v): if v.rehab: return {"error": "You are under Rehab award effect!"}, 400 @@ -143,7 +143,7 @@ def blackjack_player_stay(v): @app.post("/casino/twentyone/double-down") @limiter.limit("100/minute;2000/hour;12000/day") -@auth_required +@admin_level_required(3) def blackjack_player_doubled_down(v): if v.rehab: return {"error": "You are under Rehab award effect!"}, 400 @@ -158,7 +158,7 @@ def blackjack_player_doubled_down(v): @app.post("/casino/twentyone/buy-insurance") @limiter.limit("100/minute;2000/hour;12000/day") -@auth_required +@admin_level_required(3) def blackjack_player_bought_insurance(v): if v.rehab: return {"error": "You are under Rehab award effect!"}, 400 @@ -173,7 +173,7 @@ def blackjack_player_bought_insurance(v): # Roulette @app.get("/casino/roulette/bets") @limiter.limit("100/minute;2000/hour;12000/day") -@auth_required +@admin_level_required(3) def roulette_get_bets(v): if v.rehab: return {"error": "You are under Rehab award effect!"}, 400 @@ -185,7 +185,7 @@ def roulette_get_bets(v): @app.post("/casino/roulette/place-bet") @limiter.limit("100/minute;2000/hour;12000/day") -@auth_required +@admin_level_required(3) def roulette_player_placed_bet(v): if v.rehab: return {"error": "You are under Rehab award effect!"}, 400 @@ -205,4 +205,4 @@ def roulette_player_placed_bet(v): return {"success": True, "bets": bets, "gambler": {"coins": v.coins, "procoins": v.procoins}} except: - return {"error": "Unable to place a bet."}, 400 \ No newline at end of file + return {"error": "Unable to place a bet."}, 400