mirror of
https://code.forgejo.org/actions/setup-node.git
synced 2025-06-08 05:01:11 +00:00
minor fix
This commit is contained in:
parent
360977cce6
commit
2d741fbf57
3 changed files with 20 additions and 12 deletions
|
@ -22,10 +22,14 @@ export default class NightlyNodejs extends BaseDistribution {
|
|||
);
|
||||
|
||||
for (let i = versions.length - 1; i >= 0; i--) {
|
||||
const potential: string = versions[i].replace('nightly', 'nightly.');
|
||||
const satisfied: boolean = semver.satisfies(potential, range, {
|
||||
includePrerelease: includePrerelease
|
||||
});
|
||||
const potential: string = versions[i];
|
||||
const satisfied: boolean = semver.satisfies(
|
||||
potential.replace('nightly', 'nightly.'),
|
||||
range,
|
||||
{
|
||||
includePrerelease: includePrerelease
|
||||
}
|
||||
);
|
||||
if (satisfied) {
|
||||
version = potential;
|
||||
break;
|
||||
|
|
|
@ -18,10 +18,14 @@ export default class CanaryBuild extends BaseDistribution {
|
|||
);
|
||||
|
||||
for (let i = versions.length - 1; i >= 0; i--) {
|
||||
const potential: string = versions[i].replace('v8-canary', 'v8-canary.');
|
||||
const satisfied: boolean = semver.satisfies(potential, range, {
|
||||
includePrerelease: includePrerelease
|
||||
});
|
||||
const potential: string = versions[i];
|
||||
const satisfied: boolean = semver.satisfies(
|
||||
potential.replace('v8-canary', 'v8-canary.'),
|
||||
range,
|
||||
{
|
||||
includePrerelease: includePrerelease
|
||||
}
|
||||
);
|
||||
if (satisfied) {
|
||||
version = potential;
|
||||
break;
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue