Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Hide follower-only pinned statuses from logged-out users #1196

Merged

Conversation

johnholdun
Copy link

Fixes #1178

@@ -29,7 +29,7 @@ def show
end

if current_user.nil?
@pinned_statuses = cache_collection(@account.pinned_statuses.without_local_only, Status) if show_pinned_statuses?
@pinned_statuses = cache_collection(filtered_pinned_statuses.without_local_only, Status) if show_pinned_statuses?
Copy link
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This scoped collection was already defined in the profile—it limits to just pinned statuses that have a visibility of public or unlisted, then the without_local_only scope further limits the collection.

@@ -120,6 +120,11 @@
expect(response.body).to include(I18n.t('stream_entries.pinned'))
end

it 'does not render private pinned status' do
Copy link
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This spec should pass but something about my local environment was making controller specs raise errors. Something about Webpack not generating a manifest. I'll look into this in the future, but I wanted to make sure this was in here.

@dariusk dariusk merged commit fe340a6 into hometown-fork:hometown-dev Nov 11, 2022
@dariusk
Copy link

dariusk commented Nov 11, 2022

Thank you!!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

pinned private replies shown as public
2 participants