This commit is contained in:
ThatOneCalculator 2022-09-15 15:32:25 -07:00
parent 6a2fc8ec3b
commit e9445561fd
1 changed files with 7 additions and 3 deletions

View File

@ -15,10 +15,14 @@ export const paramDef = {
// eslint-disable-next-line import/no-default-export // eslint-disable-next-line import/no-default-export
export default define(meta, paramDef, async () => { export default define(meta, paramDef, async () => {
let tag_name = 'v12.119.0-calc'; let tag_name;
fetch('https://codeberg.org/api/v1/repos/thatonecalculator/calckey/releases?draft=false&pre-release=false&page=1&limit=1') await fetch('https://codeberg.org/api/v1/repos/thatonecalculator/calckey/releases?draft=false&pre-release=false&page=1&limit=1')
.then((response) => response.json()) .then((response) => response.json())
.then((data) => { tag_name = data[0].tag_name; }); .then((data) => {
console.log(data[0]);
console.log(data[0].tag_name);
tag_name = data[0].tag_name;
});
return { return {
tag_name, tag_name,