diff --git a/app/community/routes.py b/app/community/routes.py index d69c3c1e..9bf9287e 100644 --- a/app/community/routes.py +++ b/app/community/routes.py @@ -98,6 +98,9 @@ def add_remote(): else: flash(_('Community not found. If you are searching for a nsfw community it is blocked by this instance.'), 'warning') + if new_community.banned: + flash(_('That community is banned from %(site)s.', site=g.site.name), 'warning') + return render_template('community/add_remote.html', title=_('Add remote community'), form=form, new_community=new_community, subscribed=community_membership(current_user, new_community) >= SUBSCRIPTION_MEMBER, moderating_communities=moderating_communities(current_user.get_id()), diff --git a/app/templates/community/add_remote.html b/app/templates/community/add_remote.html index 368ca106..f756d0b3 100644 --- a/app/templates/community/add_remote.html +++ b/app/templates/community/add_remote.html @@ -17,7 +17,7 @@ - {% if new_community %} + {% if new_community and not new_community.banned %}