larxius commited on
Commit
828e38b
·
verified ·
1 Parent(s): ed20d09

Update backend_structured/routes.py

Browse files
Files changed (1) hide show
  1. backend_structured/routes.py +2 -0
backend_structured/routes.py CHANGED
@@ -1713,6 +1713,8 @@ def create_scan(current_user):
1713
  is_unlimited = True
1714
  elif quota.used_count < quota.allocated_count:
1715
  has_quota = True
 
 
1716
 
1717
  if not has_quota:
1718
  return jsonify({"message": f"Quota exceeded: You do not have enough quota for a {scan_type} Scan. Please upgrade your plan."}), 403
 
1713
  is_unlimited = True
1714
  elif quota.used_count < quota.allocated_count:
1715
  has_quota = True
1716
+ elif user_level >= requested_level:
1717
+ has_quota = True
1718
 
1719
  if not has_quota:
1720
  return jsonify({"message": f"Quota exceeded: You do not have enough quota for a {scan_type} Scan. Please upgrade your plan."}), 403