Skip to content

fix(permissions): fix public link sharing of docs#1200

Merged
synoet merged 13 commits intomainfrom
synoet/fix-public-accesss-documents
Jan 27, 2026
Merged

fix(permissions): fix public link sharing of docs#1200
synoet merged 13 commits intomainfrom
synoet/fix-public-accesss-documents

Conversation

@synoet
Copy link
Copy Markdown
Contributor

@synoet synoet commented Jan 27, 2026

Fixes ability to view publicly shared documents as an unauthenticated user.

  • User Extractors, and permissions checks weren't accoiunting for unauthenticated user
  • Soup was doing a very aggresive redirect on unauthenticated. Prevented if the user also has a document split open
  • The ShareMenu menu was using the itemType instead of the BlockName | BlockAlias to construct the share link which would result in a /app/document/<id> which is not a valid block

@github-actions
Copy link
Copy Markdown

github-actions bot commented Jan 27, 2026

@synoet synoet changed the title fix(permissions): fix public link sharing of docs" fix(permissions): fix public link sharing of docs Jan 27, 2026
@synoet synoet marked this pull request as ready for review January 27, 2026 17:30
@synoet synoet requested review from a team as code owners January 27, 2026 17:30
#[tracing::instrument(skip(db))]
pub async fn get_public_access_level(
db: &Pool<Postgres>,
document_id: &str,
Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

please update to entity_id and entity_type so we can expand this for other public things like chat and project which i assume have the same bug

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

good point 👍🏻

@claude
Copy link
Copy Markdown
Contributor

claude bot commented Jan 27, 2026


Code review

No issues found. Checked for bugs and CLAUDE.md compliance.


@macro-inc macro-inc deleted a comment from claude bot Jan 27, 2026
@synoet synoet requested a review from whutchinson98 January 27, 2026 19:45
Copy link
Copy Markdown

@Nikolay-Pomytkin Nikolay-Pomytkin left a comment

Choose a reason for hiding this comment

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

good work

@synoet synoet merged commit b9f58e9 into main Jan 27, 2026
40 checks passed
@synoet synoet deleted the synoet/fix-public-accesss-documents branch January 27, 2026 21:54
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.

3 participants