Skip to content

Commit

Permalink
Merge pull request #2076 from Civolilah/bugfix/app-version-fix
Browse files Browse the repository at this point in the history
[Bugfix] App Version Checks
  • Loading branch information
beganovich authored Oct 22, 2024
2 parents 9ba239d + 1e29365 commit f01088a
Showing 1 changed file with 6 additions and 7 deletions.
13 changes: 6 additions & 7 deletions src/components/AboutModal.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -36,6 +36,7 @@ import { useQuery } from 'react-query';
import { PasswordConfirmation } from './PasswordConfirmation';
import { useSetAtom } from 'jotai';
import { lastPasswordEntryTimeAtom } from '$app/common/atoms/password-confirmation';
import axios from 'axios';

interface SystemInfo {
system_health: boolean;
Expand Down Expand Up @@ -100,11 +101,11 @@ export function AboutModal(props: Props) {
const [systemInfo, setSystemInfo] = useState<SystemInfo>();

const { data: latestVersion } = useQuery({
queryKey: ['/api/v1/self-update/check_version'],
queryKey: ['/pdf.invoicing.co/api/version'],
queryFn: () =>
request('POST', endpoint('/api/v1/self-update/check_version')).then(
(response) => response.data
),
axios
.get('https://pdf.invoicing.co/api/version')
.then((response) => response.data),
staleTime: Infinity,
});

Expand Down Expand Up @@ -527,9 +528,7 @@ export function AboutModal(props: Props) {
onClose={() => {}}
disableClosing
>
<span className="text-center py-3 font-medium">
{t('in_progress')}
</span>
<span className="text-center py-3 font-medium">{t('in_progress')}</span>
</Modal>

<PasswordConfirmation
Expand Down

0 comments on commit f01088a

Please sign in to comment.