Skip to content

AO3-6521 Show titles of restricted related works to admins#5259

Closed
talvalin wants to merge 6 commits intootwcode:masterfrom
talvalin:AO3-6521
Closed

AO3-6521 Show titles of restricted related works to admins#5259
talvalin wants to merge 6 commits intootwcode:masterfrom
talvalin:AO3-6521

Conversation

@talvalin
Copy link
Copy Markdown
Contributor

@talvalin talvalin commented Jul 9, 2025

Pull Request Checklist

Issue

https://otwarchive.atlassian.net/browse/AO3-6521

Purpose

Fixes a problem where the titles of restricted related works are not shown to admins.

Credit

talvalin
he/him

@sarken sarken changed the title A03 6521 - Fix issue where the titles of restricted related works are not shown to admins A03 6521 Show titles of restricted related works to admins Jul 10, 2025
@sarken sarken changed the title A03 6521 Show titles of restricted related works to admins A03-6521 Show titles of restricted related works to admins Jul 10, 2025
@Bilka2 Bilka2 changed the title A03-6521 Show titles of restricted related works to admins AO3-6521 Show titles of restricted related works to admins Jul 10, 2025
Copy link
Copy Markdown
Contributor

@ceithir ceithir left a comment

Choose a reason for hiding this comment

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

Test? At first glance, adding a When I am logged in as an admin block to https://github.com/otwcode/otwarchive/blob/master/features/works/work_related.feature#L324 seems like it would do the trick.

locale: default_locale)
end
elsif related_work.restricted? && (download || !logged_in?)
elsif related_work.restricted? && (download || (!logged_in? && !logged_in_as_admin?))
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

Suggested change
elsif related_work.restricted? && (download || (!logged_in? && !logged_in_as_admin?))
elsif related_work.restricted? && (download || guest?)

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

Cf

def guest?
!(logged_in? || logged_in_as_admin?)
end

@Bilka2
Copy link
Copy Markdown
Contributor

Bilka2 commented Apr 14, 2026

Adopted at #5730

@Bilka2 Bilka2 closed this Apr 14, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants