mirror of
https://github.com/Mintplex-Labs/anything-llm.git
synced 2024-11-15 02:50:10 +01:00
Fallback logo on offline mode
This commit is contained in:
parent
122f29069c
commit
9640eb7650
@ -12,7 +12,9 @@ export default function useLogo() {
|
||||
async function fetchInstanceLogo() {
|
||||
try {
|
||||
const logoURL = await System.fetchLogo(!prefersDarkMode);
|
||||
setLogo(logoURL);
|
||||
logoURL
|
||||
? setLogo(logoURL)
|
||||
: setLogo(prefersDarkMode ? AnythingLLMLight : AnythingLLMDark);
|
||||
} catch (err) {
|
||||
setLogo(prefersDarkMode ? AnythingLLMLight : AnythingLLMDark);
|
||||
console.error("Failed to fetch logo:", err);
|
||||
|
Loading…
Reference in New Issue
Block a user