diff --git a/src/lib/components/chat/Controls/Controls.svelte b/src/lib/components/chat/Controls/Controls.svelte index 5b2a289e5..2a0b40076 100644 --- a/src/lib/components/chat/Controls/Controls.svelte +++ b/src/lib/components/chat/Controls/Controls.svelte @@ -30,7 +30,7 @@ - {#if $user.role === 'admin' || $user.permissions.chat?.controls} + {#if $user.role === 'admin' || $user?.permissions.chat?.controls}
{#if chatFiles.length > 0} diff --git a/src/lib/components/chat/MessageInput/InputMenu.svelte b/src/lib/components/chat/MessageInput/InputMenu.svelte index a37653d99..95807e81b 100644 --- a/src/lib/components/chat/MessageInput/InputMenu.svelte +++ b/src/lib/components/chat/MessageInput/InputMenu.svelte @@ -114,7 +114,7 @@
{/if} - {#if $config?.features?.enable_web_search && ($user.role === 'admin' || $user.permissions.features?.web_search)} + {#if $config?.features?.enable_web_search && ($user.role === 'admin' || $user?.permissions?.features?.web_search)} - {#if $config?.features.enable_image_generation && !readOnly} + {#if $config?.features.enable_image_generation && ($user.role === 'admin' || $user?.permissions?.features?.image_generation) && !readOnly}