mirror of
https://github.com/pocket-id/pocket-id.git
synced 2025-12-19 19:45:32 +03:00
14 lines
386 B
TypeScript
14 lines
386 B
TypeScript
import { version as currentVersion } from '$app/environment';
|
|
import APIService from './api-service';
|
|
|
|
export default class VersionService extends APIService {
|
|
getNewestVersion = async () => {
|
|
const response = await this.api
|
|
.get('/version/latest', { timeout: 2000 })
|
|
.then((res) => res.data);
|
|
return response.latestVersion;
|
|
};
|
|
|
|
getCurrentVersion = () => currentVersion;
|
|
}
|