owncloud / owncloud/ocis

[Sharing NG] Searching for share recipients with search terms <= 2 characters fails

Open
#9,000 5 comments 0 reactions 0 assignees View on GitHub
Type:Bug
Dominant language
Go
Stars
2.1k
Forks
274
Avg merge
2d 1h
Merged PRs (30d)
103

Description

## Describe the bug
Searching for share recipients with search terms that are <= 2 characters fails for non-admins.

## Steps to reproduce
1. As non-admin user, search for users with the search term "ma": `https://host.docker.internal:9200/graph/v1.0/users?$search="ma"`
2. As non-admin user, search for groups with the search term "ma": `https://host.docker.internal:9200/graph/v1.0/groups?$search="ma"`

## Expected behavior
The server responds with all found users/groups.

## Actual behavior
The server responds with `search term too short`.

If this is an intentional restriction, we need to consider removing the `search_min_length` capability as those 2 things don't go along. Honestly though, I find that config unnecessary either way.

Contributor guide

Open the contributing guide

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.