Skip to content

Commit

Permalink
fix(hashicorp): check input before isValid
Browse files Browse the repository at this point in the history
  • Loading branch information
rarkins committed Mar 5, 2020
1 parent fe2de4e commit fee7fa0
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion lib/versioning/hashicorp/index.ts
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@ const isLessThanRange = (version: string, range: string): boolean =>
npm.isLessThanRange(hashicorp2npm(version), hashicorp2npm(range));

export const isValid = (input: string): string | boolean =>
npm.isValid(hashicorp2npm(input));
input && npm.isValid(hashicorp2npm(input));

const matches = (version: string, range: string): boolean =>
npm.matches(hashicorp2npm(version), hashicorp2npm(range));
Expand Down

0 comments on commit fee7fa0

Please sign in to comment.