From 1b03f94e8a1b3d8bffb91cdfa27c7ae6e19eaaf1 Mon Sep 17 00:00:00 2001 From: thororen1234 <78185467+thororen1234@users.noreply.github.com> Date: Sun, 1 Feb 2026 17:37:06 -0500 Subject: [PATCH] Update Authors Co-Authored-By: Etorix <92535668+etorixdev@users.noreply.github.com> --- src/components/settings/tabs/plugins/PluginModal.tsx | 8 ++------ 1 file changed, 2 insertions(+), 6 deletions(-) diff --git a/src/components/settings/tabs/plugins/PluginModal.tsx b/src/components/settings/tabs/plugins/PluginModal.tsx index f4512870c..d287b8340 100644 --- a/src/components/settings/tabs/plugins/PluginModal.tsx +++ b/src/components/settings/tabs/plugins/PluginModal.tsx @@ -84,22 +84,18 @@ export default function PluginModal({ plugin, onRestartNeeded, onClose, transiti useEffect(() => { (async () => { - const loadedAuthors: Partial[] = []; - - for (const user of plugin.authors.slice(0, 6)) { + for (const [index, user] of plugin.authors.slice(0, 6).entries()) { try { const author = user.id ? await UserUtils.getUser(String(user.id)) .catch(() => makeDummyUser({ username: user.name })) : makeDummyUser({ username: user.name }); - loadedAuthors.push(author); + setAuthors(a => index === 0 ? [author] : [...a, author]); } catch (e) { continue; } } - - setAuthors(loadedAuthors.length ? loadedAuthors : [dummyAuthor]); })(); }, [plugin.authors]);