Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[stable18] fix s3 doesDirectoryExist check for empty directories #22777

Merged
merged 2 commits into from Sep 11, 2020

Conversation

backportbot-nextcloud[bot]
Copy link

backport of #22747

icewind1991 and others added 2 commits September 10, 2020 13:14
if a directory is empty, only the 'marker' object `/` exists.

since not all s3 implementations return just the prefix when listing objects by prefix,
when listing objects by the folder prefix, nothing will be returned if the directory is empty.
by not including the trailing slash in the prefix, the folder marked will always be returned if it exists

Signed-off-by: Robin Appelman <robin@icewind.nl>
…ermined

Signed-off-by: Julius Härtl <jus@bitgrid.net>
Copy link
Member

@MorrisJobke MorrisJobke left a comment

Choose a reason for hiding this comment

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

🐘

@MorrisJobke MorrisJobke added 3. to review Waiting for reviews bug labels Sep 10, 2020
Copy link
Member

@rullzer rullzer left a comment

Choose a reason for hiding this comment

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

Sure

@rullzer rullzer merged commit 0a9979d into stable18 Sep 11, 2020
@rullzer rullzer deleted the backport/22747/stable18 branch September 11, 2020 06:48
@rullzer rullzer mentioned this pull request Sep 28, 2020
1 task
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
3. to review Waiting for reviews bug
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

4 participants