diff --git a/files/classes/user.py b/files/classes/user.py index e39d29cf8..b8de28f12 100644 --- a/files/classes/user.py +++ b/files/classes/user.py @@ -278,6 +278,8 @@ class User(Base): @property @lazy def paid_dues(self): + if not FEATURES['COUNTRY_CLUB']: + return True return not self.shadowbanned and not (self.is_banned and not self.unban_utc) and (self.admin_level or self.club_allowed or (self.club_allowed != False and self.truecoins > dues)) @lazy diff --git a/files/helpers/const.py b/files/helpers/const.py index 168f9e962..348da529c 100644 --- a/files/helpers/const.py +++ b/files/helpers/const.py @@ -148,6 +148,7 @@ FEATURES = { 'AWARDS': True, 'CHAT': True, 'PINS': True, + 'COUNTRY_CLUB': True, 'PRONOUNS': False, 'BADGES': True, 'HOUSES': False, @@ -334,6 +335,7 @@ elif SITE == 'lgbdropthet.com': FEATURES['PROCOINS'] = False FEATURES['AWARDS'] = False FEATURES['CHAT'] = False + FEATURES['COUNTRY_CLUB'] = False FEATURES['BADGES'] = False FEATURES['GAMBLING'] = False FEATURES['USERS_PROFILE_BANNER'] = False diff --git a/files/routes/front.py b/files/routes/front.py index 3f3d464f2..a39265eb6 100644 --- a/files/routes/front.py +++ b/files/routes/front.py @@ -98,7 +98,7 @@ def frontlist(v=None, sort="hot", page=1, t="all", ids_only=True, ccmode="false" if not gt and not lt: posts = apply_time_filter(t, posts, Submission) - if (ccmode == "true"): + if (ccmode == "true") and FEATURES['COUNTRY_CLUB']: posts = posts.filter(Submission.club == True) posts = posts.filter_by(is_banned=False, private=False, deleted_utc = 0) diff --git a/files/routes/posts.py b/files/routes/posts.py index 1a4b1712f..38079c260 100644 --- a/files/routes/posts.py +++ b/files/routes/posts.py @@ -31,6 +31,8 @@ titleheaders = {"User-Agent": "Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWe @app.post("/toggle_club/") @auth_required def toggle_club(pid, v): + if not FEATURES['COUNTRY_CLUB']: + abort(403) post = get_post(pid) if post.author_id != v.id and v.admin_level < 2: abort(403) @@ -906,7 +908,9 @@ def submit_post(v, sub=None): if len(body_html) > 40000: return error("Submission body_html too long! (max 40k characters)") - club = bool(request.values.get("club","")) + club = False + if FEATURES['COUNTRY_CLUB']: + club = bool(request.values.get("club","")) if embed and len(embed) > 1500: embed = None diff --git a/files/templates/home.html b/files/templates/home.html index 530893658..a03b9647b 100644 --- a/files/templates/home.html +++ b/files/templates/home.html @@ -44,7 +44,7 @@ Pins {% endif %} - {% if v and SITE_NAME == 'rDrama' %} + {% if v and SITE_NAME == 'rDrama' and FEATURES['COUNTRY_CLUB'] %} {% if v.paid_dues %} {% if ccmode=="true" %} CC diff --git a/files/templates/post_actions.html b/files/templates/post_actions.html index 713d027e9..c510f8903 100644 --- a/files/templates/post_actions.html +++ b/files/templates/post_actions.html @@ -55,7 +55,7 @@ Unpin fron /h/{{p.sub}} {% endif %} - {% if v.admin_level > 1 or v.id == p.author_id %} + {% if FEATURES['COUNTRY_CLUB'] and (v.admin_level > 1 or v.id == p.author_id) %} Mark club Unmark club {% endif %} diff --git a/files/templates/post_actions_mobile.html b/files/templates/post_actions_mobile.html index 0956392e9..7a950e158 100644 --- a/files/templates/post_actions_mobile.html +++ b/files/templates/post_actions_mobile.html @@ -39,8 +39,10 @@ + {% if FEATURES['COUNTRY_CLUB'] -%} + {%- endif %} diff --git a/files/templates/post_admin_actions_mobile.html b/files/templates/post_admin_actions_mobile.html index 49d6b22bc..08201df2e 100644 --- a/files/templates/post_admin_actions_mobile.html +++ b/files/templates/post_admin_actions_mobile.html @@ -13,8 +13,10 @@ {% endif %} + {% if FEATURES['COUNTRY_CLUB'] -%} + {%- endif %} diff --git a/files/templates/submit.html b/files/templates/submit.html index 19c83553d..59000d3f8 100644 --- a/files/templates/submit.html +++ b/files/templates/submit.html @@ -176,10 +176,12 @@ + {% if FEATURES['COUNTRY_CLUB'] -%}
+ {%- endif %}
diff --git a/files/templates/user_listing.html b/files/templates/user_listing.html index b57bf9160..884857fd2 100644 --- a/files/templates/user_listing.html +++ b/files/templates/user_listing.html @@ -29,7 +29,7 @@ last active {{u.last_active_date}} {%- endif %} - {% if not hide_bios and u.bio_html %} + {% if FEATURES['USERS_PROFILE_BODYTEXT'] and not hide_bios and u.bio_html %}
{{u.bio_html | safe}}
{% endif %}
diff --git a/files/templates/userpage.html b/files/templates/userpage.html index 1da3d6740..66eec2ebb 100644 --- a/files/templates/userpage.html +++ b/files/templates/userpage.html @@ -328,8 +328,11 @@

+						{% if FEATURES['COUNTRY_CLUB'] -%}
 						
 						
+						{%- endif %}
+
 						{% endif %}
 					

 					
@@ -579,8 +582,10 @@ {% if v.admin_level > 1 %} + {% if FEATURES['COUNTRY_CLUB'] -%} + {%- endif %}