Skip to content
Snippets Groups Projects
Commit fee7fa0d authored by Rhys Arkins's avatar Rhys Arkins
Browse files

fix(hashicorp): check input before isValid

parent fe2de4ed
No related branches found
No related tags found
No related merge requests found
......@@ -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));
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment