From a4a0f08c6046cb7d5f06bb2534553255e9a183ab Mon Sep 17 00:00:00 2001 From: Joren V <9069536+jorenn92@users.noreply.github.com> Date: Sun, 11 Feb 2024 01:39:25 +0100 Subject: [PATCH] Fix: Failure to fetch latest GitHub version crashes the UI (#891) --- ui/src/components/Settings/Plex/index.tsx | 2 +- ui/src/components/VersionStatus/index.tsx | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/ui/src/components/Settings/Plex/index.tsx b/ui/src/components/Settings/Plex/index.tsx index 28738782..8bce07ae 100644 --- a/ui/src/components/Settings/Plex/index.tsx +++ b/ui/src/components/Settings/Plex/index.tsx @@ -416,7 +416,7 @@ const PlexSettings = () => { type="text" ref={hostnameRef} defaultValue={settingsCtx.settings.plex_hostname - .replace('http://', '') + ?.replace('http://', '') .replace('https://', '')} > diff --git a/ui/src/components/VersionStatus/index.tsx b/ui/src/components/VersionStatus/index.tsx index 753643e2..dbe9bc55 100644 --- a/ui/src/components/VersionStatus/index.tsx +++ b/ui/src/components/VersionStatus/index.tsx @@ -85,7 +85,7 @@ const VersionStatus = ({ onClick }: VersionStatusProps) => { messages.OUT_OF_DATE ) : ( - {version.replace('develop-', '')} + {version ? version.replace('develop-', '') : ''} )}