Skip to content

Backport/8284/stable31#8341

Open
JuliaKirschenheuter wants to merge 7 commits intostable31from
backport/8284/stable31
Open

Backport/8284/stable31#8341
JuliaKirschenheuter wants to merge 7 commits intostable31from
backport/8284/stable31

Conversation

@JuliaKirschenheuter
Copy link
Contributor

📝 Summary

Backport for #8284

🏁 Checklist

  • Code is properly formatted (npm run lint / npm run stylelint / composer run cs:check)
  • Sign-off message is added to all commits
  • Tests (unit, integration and/or end-to-end) passing and the changes are covered with tests
  • Documentation (README or documentation) has been updated or is not required

rikled added 7 commits March 16, 2026 11:50
Signed-off-by: Hendrik Leidinger <hendrik.leidinger@nextcloud.com>
Signed-off-by: Hendrik Leidinger <hendrik.leidinger@nextcloud.com>
Signed-off-by: Hendrik Leidinger <hendrik.leidinger@nextcloud.com>
Signed-off-by: Hendrik Leidinger <hendrik.leidinger@nextcloud.com>
Signed-off-by: Hendrik Leidinger <hendrik.leidinger@nextcloud.com>
Signed-off-by: Hendrik Leidinger <hendrik.leidinger@nextcloud.com>
Signed-off-by: Hendrik Leidinger <hendrik.leidinger@nextcloud.com>
Signed-off-by: julia.kirschenheuter <julia.kirschenheuter@nextcloud.com>

# Conflicts:
#	tests/unit/Service/ApiServiceTest.php
// Disable file locking for Readme.md files, because in the
// current setup, this makes it almost impossible to delete these files.
/** @psalm-suppress RedundantCastGivenDocblockType */
if (!$readOnly && strcasecmp((string)$file->getName(), 'Readme.md') !== 0) {
Copy link
Contributor

Choose a reason for hiding this comment

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

I think we don't need the string cast anymore since I added a name in the ApiServiceTest.php

Copy link
Contributor

Choose a reason for hiding this comment

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

Then you should also be able to remove /** @psalm-suppress RedundantCastGivenDocblockType */

Copy link
Contributor Author

Choose a reason for hiding this comment

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

thank you @rikled! Then it will look like:

if (!$readOnly) { 

Copy link
Contributor

Choose a reason for hiding this comment

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

No, I think it should look like this:

		// Disable file locking for Readme.md files, because in the
		// current setup, this makes it almost impossible to delete these files.
		if (!$readOnly && strcasecmp($file->getName(), 'Readme.md') !== 0) {

so just remove the string cast and the psalm suppress command. Then hopefully the php unit tests will still pass.

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.

2 participants