diff --git a/Changelog.md b/Changelog.md index e5e89107f..d93ba417d 100644 --- a/Changelog.md +++ b/Changelog.md @@ -13,6 +13,7 @@ * Make the \#newhere post public again [#7311](https://github.com/diaspora/diaspora/pull/7311) * Remove whitespace from author link [#7330](https://github.com/diaspora/diaspora/pull/7330) * Fix autosize in modals [#7339](https://github.com/diaspora/diaspora/pull/7339) +* Only display invite link on contacts page if invitations are enabled [#7342](https://github.com/diaspora/diaspora/pull/7342) ## Features * Add support for [Liberapay](https://liberapay.com) donations [#7290](https://github.com/diaspora/diaspora/pull/7290) diff --git a/app/views/contacts/_sidebar.html.haml b/app/views/contacts/_sidebar.html.haml index 8ed81bd57..111097bab 100644 --- a/app/views/contacts/_sidebar.html.haml +++ b/app/views/contacts/_sidebar.html.haml @@ -2,14 +2,18 @@ %h3 = t("contacts.index.title") = render "contacts/aspect_listings" -%hr -- if AppConfig.settings.community_spotlight.enable? - .text-center.spotlight - = link_to t("contacts.spotlight.community_spotlight"), community_spotlight_path, class: "btn btn-link" -.text-center - #invitations-button.btn.btn-link{ "data-toggle" => "modal" } - = t("invitations.new.invite_someone_to_join") - = render "shared/modal", - path: new_user_invitation_path, - id: "invitationsModal", - title: t("invitations.new.invite_someone_to_join") +- if AppConfig.settings.community_spotlight.enable? || AppConfig.settings.invitations.open? + %hr + - if AppConfig.settings.community_spotlight.enable? + .text-center.spotlight + = link_to t("contacts.spotlight.community_spotlight"), + community_spotlight_path, + class: "btn btn-link" + - if AppConfig.settings.invitations.open? + .text-center + .btn.btn-link#invitations-button{"data-toggle" => "modal"} + = t("invitations.new.invite_someone_to_join") + = render "shared/modal", + path: new_user_invitation_path, + id: "invitationsModal", + title: t("invitations.new.invite_someone_to_join")