diff options
| author | Owen Jacobson <owen@grimoire.ca> | 2025-02-24 11:41:24 -0500 |
|---|---|---|
| committer | Owen Jacobson <owen@grimoire.ca> | 2025-02-24 11:41:24 -0500 |
| commit | 099471c574f6dceeb45f8bb5dae1699a734cb084 (patch) | |
| tree | 945f44c9a90bf51de20c61a5a8c5ed82c2c05009 /ui/lib/components/Invites.svelte | |
| parent | 36cadfe00cacc6a6523f9862d3f7a08a9d0ce611 (diff) | |
| parent | fc0f1654a56d2247728a766f43e72ff169704888 (diff) | |
Merge branch 'prop/global-state-at-top-level'
Diffstat (limited to 'ui/lib/components/Invites.svelte')
| -rw-r--r-- | ui/lib/components/Invites.svelte | 8 |
1 files changed, 2 insertions, 6 deletions
diff --git a/ui/lib/components/Invites.svelte b/ui/lib/components/Invites.svelte index 27d3754..226ccce 100644 --- a/ui/lib/components/Invites.svelte +++ b/ui/lib/components/Invites.svelte @@ -1,15 +1,11 @@ <script> - import { createInvite } from '$lib/apiServer'; import Invite from '$lib/components/Invite.svelte'; - let invites = $state([]); + let { invites, createInvite = async () => {} } = $props(); async function onsubmit(event) { event.preventDefault(); - let response = await createInvite(); - if (response.status == 200) { - invites.push(response.data); - } + await createInvite(); } </script> |
