Fix a couple bugs

This commit is contained in:
Jon Staab 2023-12-18 10:15:02 -08:00
parent 07741d5441
commit cf1554e1c9
3 changed files with 5 additions and 3 deletions

View File

@ -8,6 +8,7 @@
import OverflowMenu from "src/partials/OverflowMenu.svelte"
import {router} from "src/app/router"
import {
session,
deriveAdminKeyForGroup,
leaveGroup,
joinGroup,
@ -81,7 +82,7 @@
</script>
<div class="flex items-center gap-3" on:click|stopPropagation>
{#if !$adminKey}
{#if !$adminKey && $session}
{#if $access === GroupAccess.Open}
{#if $status.joined}
<Popover triggerType="mouseenter">

View File

@ -13,6 +13,7 @@
groups,
canUseGiftWrap,
getUserRelayUrls,
selectHints,
mergeHints,
getGroupReqInfo,
deriveMembershipLevel,
@ -52,7 +53,7 @@
})
load({
relays: getUserRelayUrls("read"),
relays: selectHints(getUserRelayUrls("read")),
filters: [
{kinds: [34550], authors: admins},
{kinds: [34550], limit: 100},

View File

@ -77,7 +77,7 @@
const groupOptions = session.derived($session => {
const options = []
for (const address of Object.keys($session.groups || {})) {
for (const address of Object.keys($session?.groups || {})) {
const group = groups.key(address).get()
if (group && deriveMembershipLevel(address).get()) {