Skip to content

Commit 2ace6a3

Browse files
committed
fix(sharing): set STATUS_ACCEPTED when creating USERGROUP subshare on move
When an ownCloud-migrated group share (which has no per-user USERGROUP subshare) is renamed for the first time, DefaultShareProvider::move() inserts a new USERGROUP row without setting `accepted`. The column defaults to 0 (STATUS_PENDING), causing MountProvider to skip the share on the next request — the file disappears for the recipient. Native Nextcloud group shares are unaffected because the accept flow always creates the USERGROUP subshare and immediately sets `accepted = STATUS_ACCEPTED` before the user can rename. Fixes: #59791 AI-Assisted-By: Claude Sonnet 4.6 <noreply@anthropic.com> Signed-off-by: Anna Larch <anna@nextcloud.com>
1 parent 8365464 commit 2ace6a3

1 file changed

Lines changed: 1 addition & 0 deletions

File tree

lib/private/Share20/DefaultShareProvider.php

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -601,6 +601,7 @@ public function move(IShare $share, $recipient) {
601601
'permissions' => $qb->createNamedParameter($share->getPermissions()),
602602
'attributes' => $qb->createNamedParameter($shareAttributes),
603603
'stime' => $qb->createNamedParameter($share->getShareTime()->getTimestamp()),
604+
'accepted' => $qb->createNamedParameter(IShare::STATUS_ACCEPTED),
604605
])->executeStatement();
605606
} else {
606607
// Already a usergroup share. Update it.

0 commit comments

Comments
 (0)