Feat/allow all logged users - #231
Open
omaraelhawary wants to merge 6 commits into
Open
Conversation
Expose read/write/delete helpers and include the flag in members_has_post_permissions() so posts restricted to any logged-in user are treated as permissioned content.
Handle the new permission mode alongside role-based checks, gate access behind the login check to avoid guest bypass, and skip parent inheritance when the flag is set.
…a box. Provide a checkbox that disables role selection when enabled, persist the flag on save with mutual exclusivity against roles, and sync the UI state in edit-post.js.
Register the meta field for REST, keep role and flag meta in sync on partial updates, fix protected-meta auth for writes, and add the checkbox to the document panel.
…nt permissions panel to ensure proper re-application of default settings.
Collaborator
Author
|
Could you please review https://screenrec.com/share/TYvF7rBpdz ? |
ThemeGravity
approved these changes
Jun 15, 2026
ThemeGravity
left a comment
Contributor
There was a problem hiding this comment.
@omaraelhawary Code looks good. I left comments but they are just minor issues, nothing serious. Thanks.
…onal post_id parameter for improved flexibility. Simplify logic in members_can_user_view_post to streamline access checks for logged-in users, ensuring clarity and efficiency in permission handling.
Collaborator
Author
|
@cartpauj Could you please review https://screenrec.com/share/TYvF7rBpdz ? |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Adds a new Content Permissions option that restricts post access to any logged-in user, without requiring specific roles. This fills the gap between “public” (no roles selected) and “role-restricted” (one or more roles selected).
Previously, site owners could only restrict content to selected roles or leave it open to everyone. There was no way to say “members only” in the general sense — logged in, but not necessarily assigned a particular role.