Folder::searchByMime
does not work for folder under group folder
#3537
Labels
Folder::searchByMime
does not work for folder under group folder
#3537
How to use GitHub
Steps to reproduce
Prerequisite: Have a group folder configured and a sub-folder under it with some files. In the example below, I had a user named
root
who had access to a group folder with hierarchy like this:Register the command class shown below to some app and run it with
![Image](https://private-user-images.githubusercontent.com/8565946/403567292-ea791b73-aa40-47a4-90e2-31966fc0700d.png?jwt=eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJpc3MiOiJnaXRodWIuY29tIiwiYXVkIjoicmF3LmdpdGh1YnVzZXJjb250ZW50LmNvbSIsImtleSI6ImtleTUiLCJleHAiOjE3Mzg5MTMxMDksIm5iZiI6MTczODkxMjgwOSwicGF0aCI6Ii84NTY1OTQ2LzQwMzU2NzI5Mi1lYTc5MWI3My1hYTQwLTQ3YTQtOTBlMi0zMTk2NmZjMDcwMGQucG5nP1gtQW16LUFsZ29yaXRobT1BV1M0LUhNQUMtU0hBMjU2JlgtQW16LUNyZWRlbnRpYWw9QUtJQVZDT0RZTFNBNTNQUUs0WkElMkYyMDI1MDIwNyUyRnVzLWVhc3QtMSUyRnMzJTJGYXdzNF9yZXF1ZXN0JlgtQW16LURhdGU9MjAyNTAyMDdUMDcyMDA5WiZYLUFtei1FeHBpcmVzPTMwMCZYLUFtei1TaWduYXR1cmU9YTg3NmZhYzc2N2FkZjZmZDMyYzU0NGRhYjlkY2JlYjc2MGQ4ODlhMjBmNzUwNTA5ZmM3OWQwZjU3N2ExMGJlOSZYLUFtei1TaWduZWRIZWFkZXJzPWhvc3QifQ.8EhAbcWLXB1N0KKcnlRxsmB0ri3q7iKd9kZn-KBnfxo)
occ
for the foldersgroup_folder
andgroup_folder/subfolder
:The source code of the
occ
command used above:Expected behaviour
Folder::searchByMime
should find matching files also when used on a folder residing inside a group folder.Actual behaviour
Folder::searchByMime
does not find any matching files when used on a folder residing inside a group folder. Using the function on the group folder itself finds those files.This is the root cause of the bug owncloud/music#1195.
Server configuration
Operating system: Linux 6.1.19-v8+ aarch64
Web server: N/A
Database: SQLite 3.34.1
PHP version: 8.2.27
Nextcloud version: 30.0.2 RC1
Team folders version: 18.0.8
Updated from an older Nextcloud/ownCloud or fresh install: fresh
Where did you install Nextcloud from: https://download.nextcloud.com/server/
Are you using external storage, if yes which one: no
Are you using encryption: no
Are you using an external user-backend, if yes which one: no
Client configuration
N/A
Logs
N/A
The text was updated successfully, but these errors were encountered: