mirror of
https://github.com/seriousm4x/UpSnap.git
synced 2026-08-04 19:25:13 -04:00
fix devices would not load for normal users
This commit is contained in:
@@ -81,8 +81,12 @@
|
||||
}
|
||||
|
||||
async function getSettingsPrivateAndDevices() {
|
||||
const settingsPrivateRes = await $pocketbase.collection('settings_private').getList(1, 1);
|
||||
settings_private.set(settingsPrivateRes.items[0]);
|
||||
if (!$pocketbase.authStore.model?.collectionName === 'users') {
|
||||
const settingsPrivateRes = await $pocketbase
|
||||
.collection('settings_private')
|
||||
.getList(1, 1);
|
||||
settings_private.set(settingsPrivateRes.items[0]);
|
||||
}
|
||||
|
||||
let tempDevices = {};
|
||||
const devicesRes = await $pocketbase.collection('devices').getFullList(200, {
|
||||
|
||||
Reference in New Issue
Block a user