This commit is contained in:
Viktor Rådberg
2024-01-13 20:15:43 +01:00
parent f8f0788b97
commit 2f3ee74c74
2 changed files with 6 additions and 2 deletions

View File

@@ -1,6 +1,8 @@
name: Deploy to Firebase Hosting
'on':
push:
branches:
- main
tags:
- '*'
jobs:

View File

@@ -44,17 +44,19 @@ export const SettingsModal = ({ isOpen, closeModal }: SettingsModalProps) => {
const data = await result.json();
if (!data.name) {
setIsLatestVersion(false);
setNewVersion(undefined);
setIsLatestVersion(false);
return;
}
setNewVersion(data.name);
/* @ts-expect-error is defined in vite.config.ts*/
if (data.name === APP_VERSION) {
setNewVersion(data.name);
setIsLatestVersion(true);
return;
}
setIsLatestVersion(false);
} catch (error) {
console.error('error getting latest version string', error);