mirror of
https://github.com/MrUnknownDE/VRCX.git
synced 2026-05-05 14:26:06 +02:00
fix
This commit is contained in:
+22
-19
@@ -59,7 +59,7 @@ export const useFeedStore = defineStore('Feed', () => {
|
||||
init();
|
||||
|
||||
function feedSearch(row) {
|
||||
const value = feedTable.value.search.toUpperCase();
|
||||
const value = feedTable.value.search.trim().toUpperCase();
|
||||
if (!value) {
|
||||
return true;
|
||||
}
|
||||
@@ -140,25 +140,28 @@ export const useFeedStore = defineStore('Feed', () => {
|
||||
feedTable.value.vip
|
||||
);
|
||||
feedTable.value.loading = true;
|
||||
let vipList = [];
|
||||
if (feedTable.value.vip) {
|
||||
vipList = Array.from(friendStore.localFavoriteFriends.values());
|
||||
try {
|
||||
let vipList = [];
|
||||
if (feedTable.value.vip) {
|
||||
vipList = Array.from(friendStore.localFavoriteFriends.values());
|
||||
}
|
||||
const search = feedTable.value.search.trim();
|
||||
const rows = search
|
||||
? await database.searchFeedDatabase(
|
||||
search,
|
||||
feedTable.value.filter,
|
||||
vipList,
|
||||
vrcxStore.searchLimit
|
||||
)
|
||||
: await database.lookupFeedDatabase(
|
||||
feedTable.value.filter,
|
||||
vipList
|
||||
);
|
||||
feedTableData.value = [];
|
||||
feedTableData.value = [...feedTableData.value, ...rows];
|
||||
} finally {
|
||||
feedTable.value.loading = false;
|
||||
}
|
||||
const search = feedTable.value.search.trim();
|
||||
const rows = search
|
||||
? await database.searchFeedDatabase(
|
||||
search,
|
||||
feedTable.value.filter,
|
||||
vipList,
|
||||
vrcxStore.searchLimit
|
||||
)
|
||||
: await database.lookupFeedDatabase(
|
||||
feedTable.value.filter,
|
||||
vipList
|
||||
);
|
||||
feedTableData.value = [];
|
||||
feedTableData.value = [...feedTableData.value, ...rows];
|
||||
feedTable.value.loading = false;
|
||||
}
|
||||
|
||||
function addFeed(feed) {
|
||||
|
||||
+28
-25
@@ -397,32 +397,35 @@ export const useGameLogStore = defineStore('GameLog', () => {
|
||||
gameLogTable.value.vip
|
||||
);
|
||||
gameLogTable.value.loading = true;
|
||||
let vipList = [];
|
||||
if (gameLogTable.value.vip) {
|
||||
vipList = Array.from(friendStore.localFavoriteFriends.values());
|
||||
}
|
||||
const search = gameLogTable.value.search.trim();
|
||||
let rows = [];
|
||||
if (search) {
|
||||
rows = await database.searchGameLogDatabase(
|
||||
search,
|
||||
gameLogTable.value.filter,
|
||||
vipList,
|
||||
vrcxStore.searchLimit
|
||||
);
|
||||
} else {
|
||||
rows = await database.lookupGameLogDatabase(
|
||||
gameLogTable.value.filter,
|
||||
vipList
|
||||
);
|
||||
}
|
||||
try {
|
||||
let vipList = [];
|
||||
if (gameLogTable.value.vip) {
|
||||
vipList = Array.from(friendStore.localFavoriteFriends.values());
|
||||
}
|
||||
const search = gameLogTable.value.search.trim();
|
||||
let rows = [];
|
||||
if (search) {
|
||||
rows = await database.searchGameLogDatabase(
|
||||
search,
|
||||
gameLogTable.value.filter,
|
||||
vipList,
|
||||
vrcxStore.searchLimit
|
||||
);
|
||||
} else {
|
||||
rows = await database.lookupGameLogDatabase(
|
||||
gameLogTable.value.filter,
|
||||
vipList
|
||||
);
|
||||
}
|
||||
|
||||
for (const row of rows) {
|
||||
row.isFriend = gameLogIsFriend(row);
|
||||
row.isFavorite = gameLogIsFavorite(row);
|
||||
for (const row of rows) {
|
||||
row.isFriend = gameLogIsFriend(row);
|
||||
row.isFavorite = gameLogIsFavorite(row);
|
||||
}
|
||||
gameLogTableData.value = rows;
|
||||
} finally {
|
||||
gameLogTable.value.loading = false;
|
||||
}
|
||||
gameLogTableData.value = rows;
|
||||
gameLogTable.value.loading = false;
|
||||
}
|
||||
|
||||
function addGameLog(entry) {
|
||||
@@ -475,7 +478,7 @@ export const useGameLogStore = defineStore('GameLog', () => {
|
||||
}
|
||||
|
||||
function gameLogSearch(row) {
|
||||
const value = gameLogTable.value.search.toUpperCase();
|
||||
const value = gameLogTable.value.search.trim().toUpperCase();
|
||||
if (!value) {
|
||||
return true;
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user