mirror of
https://github.com/woodpecker-ci/woodpecker.git
synced 2024-12-24 10:07:21 +02:00
parent
5cedc956e9
commit
c746857830
@ -81,11 +81,18 @@ export function useVersion() {
|
||||
}
|
||||
}
|
||||
|
||||
let needsUpdate = false;
|
||||
if (usesNext) {
|
||||
needsUpdate = latest !== current;
|
||||
} else if (latest !== undefined && currentSemver !== null) {
|
||||
needsUpdate = semverGt(latest, currentSemver);
|
||||
}
|
||||
|
||||
version.value = {
|
||||
latest,
|
||||
current,
|
||||
currentShort: usesNext ? 'next' : current,
|
||||
needsUpdate: latest !== undefined && currentSemver !== null && semverGt(latest, currentSemver),
|
||||
needsUpdate,
|
||||
usesNext,
|
||||
};
|
||||
});
|
||||
|
Loading…
Reference in New Issue
Block a user