Skip to content

Commit

Permalink
fix: pass rangeStrategy to generateUpdate
Browse files Browse the repository at this point in the history
  • Loading branch information
rarkins committed May 14, 2021
1 parent 86739ca commit aca4798
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 1 deletion.
4 changes: 3 additions & 1 deletion lib/workers/repository/process/lookup/generate.ts
Original file line number Diff line number Diff line change
@@ -1,13 +1,15 @@
import type { Release } from '../../../../datasource';
import { logger } from '../../../../logger';
import type { LookupUpdate } from '../../../../manager/types';
import { RangeStrategy } from '../../../../types';
import type { VersioningApi } from '../../../../versioning';
import type { LookupUpdateConfig } from './types';
import { getUpdateType } from './update-type';

export function generateUpdate(
config: LookupUpdateConfig,
versioning: VersioningApi,
rangeStrategy: RangeStrategy,
currentVersion: string,
bucket: string,
release: Release
Expand All @@ -29,7 +31,7 @@ export function generateUpdate(
update[field] = release[field];
}
}
const { currentValue, rangeStrategy } = config;
const { currentValue } = config;
try {
update.newValue = versioning.getNewValue({
currentValue,
Expand Down
1 change: 1 addition & 0 deletions lib/workers/repository/process/lookup/index.ts
Original file line number Diff line number Diff line change
Expand Up @@ -226,6 +226,7 @@ export async function lookupUpdates(
const update = generateUpdate(
config,
versioning,
rangeStrategy,
lockedVersion || currentVersion,
bucket,
release
Expand Down

0 comments on commit aca4798

Please sign in to comment.