chore: fix creator initial

This commit is contained in:
Steven 2023-11-12 14:01:00 +08:00
parent 0f7a771e85
commit dddb643bed

View File

@ -31,8 +31,8 @@ const CollectionSpace = () => {
(async () => { (async () => {
try { try {
const collection = await collectionStore.fetchCollectionByName(collectionName); const collection = await collectionStore.fetchCollectionByName(collectionName);
await userStore.getOrFetchUserById(collection.creatorId);
setCollection(collection); setCollection(collection);
document.title = `${collection.title} - Slash`;
setShortcuts([]); setShortcuts([]);
for (const shortcutId of collection.shortcutIds) { for (const shortcutId of collection.shortcutIds) {
try { try {
@ -44,6 +44,7 @@ const CollectionSpace = () => {
// do nth // do nth
} }
} }
document.title = `${collection.title} - Slash`;
} catch (error: any) { } catch (error: any) {
console.error(error); console.error(error);
toast.error(error.details); toast.error(error.details);