mirror of
https://github.com/discourse/discourse.git
synced 2025-06-02 04:08:41 +08:00
FEATURE: Option to disable user presence and profile
This allows users who are privacy conscious to disable the presence features of the forum as well as their public profile.
This commit is contained in:
@ -37,6 +37,12 @@ describe ::Presence::PresencesController do
|
||||
expect { post '/presence/publish.json' }.not_to raise_error
|
||||
end
|
||||
|
||||
it "does not publish for users with disabled presence features" do
|
||||
user1.user_option.update_column(:hide_profile_and_presence, true)
|
||||
post '/presence/publish.json'
|
||||
expect(response.code).to eq("404")
|
||||
end
|
||||
|
||||
it "uses guardian to secure endpoint" do
|
||||
private_post = Fabricate(:private_message_post)
|
||||
|
||||
|
Reference in New Issue
Block a user