Correct subscripion status in 'Local' and 'Joined' for communities user has created. #8

This commit is contained in:
Andrew Slater 2024-03-03 22:09:38 +00:00
parent 4afcf56a7b
commit 6b87ca2392

View file

@ -189,7 +189,7 @@ def list_local_communities():
communities = Community.query.filter_by(ap_id=None, banned=False)
return render_template('list_communities.html', communities=communities.order_by(sort_by).all(), title=_('Local communities'), sort_by=sort_by,
SUBSCRIPTION_PENDING=SUBSCRIPTION_PENDING, SUBSCRIPTION_MEMBER=SUBSCRIPTION_MEMBER,
SUBSCRIPTION_MODERATOR=SUBSCRIPTION_MODERATOR,
SUBSCRIPTION_OWNER=SUBSCRIPTION_OWNER, SUBSCRIPTION_MODERATOR=SUBSCRIPTION_MODERATOR,
low_bandwidth=request.cookies.get('low_bandwidth', '0') == '1', moderating_communities=moderating_communities(current_user.get_id()),
joined_communities=joined_communities(current_user.get_id()))
@ -204,7 +204,7 @@ def list_subscribed_communities():
communities = []
return render_template('list_communities.html', communities=communities, title=_('Joined communities'),
SUBSCRIPTION_PENDING=SUBSCRIPTION_PENDING, SUBSCRIPTION_MEMBER=SUBSCRIPTION_MEMBER, sort_by=sort_by,
SUBSCRIPTION_MODERATOR=SUBSCRIPTION_MODERATOR,
SUBSCRIPTION_OWNER=SUBSCRIPTION_OWNER, SUBSCRIPTION_MODERATOR=SUBSCRIPTION_MODERATOR,
low_bandwidth=request.cookies.get('low_bandwidth', '0') == '1', moderating_communities=moderating_communities(current_user.get_id()),
joined_communities=joined_communities(current_user.get_id()))