Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 1 addition & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,7 @@ Changes to JS assets are not included here, but in [`atomic-data-browser`'s CHAN

- Add parent parameter to search endpoint which scopes a search to only the descendants of the given resource. #226
- Bookmark endpoint now also retrieves `og:image` and `og:description` #510
- Give server agent rights to edit all resources, fix issue with accepting invites in private drives #521

## [v0.33.1] - 2022-09-25

Expand Down
5 changes: 5 additions & 0 deletions lib/src/hierarchy.rs
Original file line number Diff line number Diff line change
Expand Up @@ -114,6 +114,11 @@ pub fn check_rights(
if resource.get_subject() == for_agent {
return Ok("Agents can always edit themselves or their children.".into());
}
if let Ok(server_agent) = store.get_default_agent() {
if server_agent.subject == for_agent {
return Ok("Server agent has root access, and can edit anything.".into());
}
}

// Handle Commits.
if let Ok(commit_subject) = resource.get(urls::SUBJECT) {
Expand Down