Skip to content

fix(files_sharing): fix share creation error handling - #52075

Merged
skjnldsv merged 2 commits into
masterfrom
fix/sharing-error-catch
Apr 9, 2025
Merged

fix(files_sharing): fix share creation error handling#52075
skjnldsv merged 2 commits into
masterfrom
fix/sharing-error-catch

Conversation

@skjnldsv

Copy link
Copy Markdown
Member

Context

When creating a share which triggers an error, I noticed some issues:

  1. The error is shown as Error creating the share: Failed to create share, which is really not acceptable
  2. The error is not caught and the spinner is still spinning
  3. The button isn't disabled while loading

How to test:

  1. Share folder Folder1 from user1 to user2
  2. As user2 move the shared folder into one of your folder Folder2
  3. Try to share Folder2 to user3

Expectations

Error stating: Error creating the share: You cannot share a folder that contains other shares

Reality

Error stating Error creating the share: Failed to create share
(And the logs states a weirdly phrased error which is also renamed in that PR: Path contains files shared with you)

@skjnldsvskjnldsv added this to the Nextcloud 32 milestone Apr 9, 2025
@skjnldsvskjnldsv self-assigned this Apr 9, 2025
@skjnldsv
skjnldsv requested review from a team as code ownersApril 9, 2025 14:16
@skjnldsv
skjnldsv requested review from icewind1991, nfebe, susnux, szaimen and yemkareems and removed request for a teamApril 9, 2025 14:16
@skjnldsv
skjnldsvforce-pushed the fix/sharing-error-catch branch 2 times, most recently from 94a3378 to 367ef8dCompareApril 9, 2025 14:23
@skjnldsv

skjnldsv commented Apr 9, 2025

Copy link
Copy Markdown
MemberAuthor

/backport 70218dc to stable31

@skjnldsv

skjnldsv commented Apr 9, 2025

Copy link
Copy Markdown
MemberAuthor

/backport 70218dc to stable30

@skjnldsv

skjnldsv commented Apr 9, 2025

Copy link
Copy Markdown
MemberAuthor

/backport 70218dc to stable29

@skjnldsv
skjnldsvforce-pushed the fix/sharing-error-catch branch from 367ef8d to 2c2239cCompareApril 9, 2025 14:31

@szaimenszaimen left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

🐘

@skjnldsv

Copy link
Copy Markdown
MemberAuthor

/compile rebase

skjnldsvand others added 2 commits April 9, 2025 14:52
Signed-off-by: skjnldsv <skjnldsv@protonmail.com>
Signed-off-by: nextcloud-command <nextcloud-command@users.noreply.github.com>
@skjnldsvskjnldsv added 4. to release Ready to be released and/or waiting for tests to finish and removed 3. to review Waiting for reviews labels Apr 9, 2025
Sign up for freeto join this conversation on GitHub. Already have an account? Sign in to comment

Labels

4. to releaseReady to be released and/or waiting for tests to finishbugfeature: sharingregression

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants

@skjnldsv@nfebe@szaimen@nextcloud-command