Regression: Settings pagination not working (#3277)

This commit is contained in:
Diego Mello 2021-07-15 11:34:39 -03:00 committed by GitHub
parent e040be0b45
commit d1702aa416
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
1 changed files with 3 additions and 2 deletions

View File

@ -138,9 +138,10 @@ export function subscribeSettings() {
export default async function() { export default async function() {
try { try {
const db = database.active; const db = database.active;
const settingsParams = JSON.stringify(Object.keys(settings).filter(key => !loginSettings.includes(key))); const settingsParams = Object.keys(settings).filter(key => !loginSettings.includes(key));
// RC 0.60.0 // RC 0.60.0
const result = await fetch(`${ this.sdk.client.host }/api/v1/settings.public?query={"_id":{"$in":${ settingsParams }}}`).then(response => response.json()); const result = await fetch(`${ this.sdk.client.host }/api/v1/settings.public?query={"_id":{"$in":${ JSON.stringify(settingsParams) }}}&count=${ settingsParams.length }`)
.then(response => response.json());
if (!result.success) { if (!result.success) {
return; return;