Skip to content

Comments

fix: Migrate getById to getFirstNodeById#16971

Closed
artonge wants to merge 1 commit intomainfrom
artonge/fix/getbyid
Closed

fix: Migrate getById to getFirstNodeById#16971
artonge wants to merge 1 commit intomainfrom
artonge/fix/getbyid

Conversation

@artonge
Copy link
Contributor

@artonge artonge commented Feb 3, 2026

No description provided.

Signed-off-by: Louis Chmn <louis@chmn.me>
Copy link
Member

@nickvergessen nickvergessen left a comment

Choose a reason for hiding this comment

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

  • Has to wait for green CI from nextcloud/server side to make sure this does not break something in parallel
  • Ref nextcloud/server#57910
  • Ref #16947

public function getUsersWithAccessFile(string $fileId): array {
if (!isset($this->accessLists[$fileId])) {
$nodes = $this->rootFolder->getById((int)$fileId);
$node = $this->rootFolder->getFirstNodeById((int)$fileId);
Copy link
Member

Choose a reason for hiding this comment

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

Copy link
Contributor Author

Choose a reason for hiding this comment

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

The combination of both would be best, IUserFolder + getFirstNodeById.

But using getFirstNodeById should already help.

Copy link
Contributor Author

@artonge artonge Feb 3, 2026

Choose a reason for hiding this comment

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

I only did the easy no-brainer change, as using IUserFolder requires looking at the logic itself to understand whether it fit the situation

Copy link
Member

Choose a reason for hiding this comment

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

Okay I will check then

@nickvergessen
Copy link
Member

@nextcloud nextcloud deleted a comment from artonge Feb 4, 2026
@nickvergessen
Copy link
Member

Merged via #16947

@nickvergessen nickvergessen deleted the artonge/fix/getbyid branch February 5, 2026 08:14
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