mirror of
https://github.com/gkd-kit/docs.git
synced 2024-11-16 13:52:19 +08:00
fix: downloadUrl
This commit is contained in:
parent
802974ded2
commit
a58b7267fc
|
@ -25,8 +25,9 @@ const downloadApk = async () => {
|
|||
onMounted(async () => {
|
||||
apkUrl.value = localStorage.getItem('apkUrl') || '';
|
||||
const versionUrl = 'https://registry.npmmirror.com/@gkd-kit/app/latest/files';
|
||||
const r = await fetch(versionUrl).then((r) => r.json());
|
||||
apkUrl.value = new URL(r.downloadUrl, r.url).href;
|
||||
const r = await fetch(versionUrl);
|
||||
const data = await r.json();
|
||||
apkUrl.value = new URL(data.downloadUrl, r.url).href;
|
||||
localStorage.setItem('apkUrl', apkUrl.value);
|
||||
});
|
||||
</script>
|
||||
|
|
Loading…
Reference in New Issue
Block a user