Skip to content
Snippets Groups Projects
Unverified Commit a1e7ac9e authored by Vincent Petry's avatar Vincent Petry
Browse files

Make user list pagination more tolerant


In case the server returns more results than expected by the limit, it
is now still interpreted as there being more results to query.

This situation can happen when there are multiple user backends in
place.

Signed-off-by: default avatarVincent Petry <vincent@nextcloud.com>
parent ee8c3561
No related branches found
No related tags found
No related merge requests found
File suppressed by a .gitattributes entry or the file's encoding is unsupported.
File suppressed by a .gitattributes entry or the file's encoding is unsupported.
......@@ -220,7 +220,7 @@ const actions = {
.then((response) => {
if (Object.keys(response.data.ocs.data.users).length > 0) {
context.commit('appendUsers', response.data.ocs.data.users)
return Object.keys(response.data.ocs.data.users).length === limit
return Object.keys(response.data.ocs.data.users).length >= limit
}
return false
})
......@@ -237,7 +237,7 @@ const actions = {
.then((response) => {
if (Object.keys(response.data.ocs.data.users).length > 0) {
context.commit('appendUsers', response.data.ocs.data.users)
return Object.keys(response.data.ocs.data.users).length === limit
return Object.keys(response.data.ocs.data.users).length >= limit
}
return false
})
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment