diff --git a/ts/smartnpm.classes.npmregistry.ts b/ts/smartnpm.classes.npmregistry.ts index f55aeec..16951e1 100644 --- a/ts/smartnpm.classes.npmregistry.ts +++ b/ts/smartnpm.classes.npmregistry.ts @@ -92,7 +92,7 @@ export class NpmRegistry { }): Promise { const npmPackage = await this.getPackageInfo(packageNameArg); if (!optionsArg?.version && !optionsArg?.distTag) { - const latestAvailable = npmPackage.allDistTags.find(packageArg => packageArg.name === 'latest'); + const latestAvailable = npmPackage.allDistTags.find(packageDistTagArg => packageDistTagArg.name === 'latest'); if (!latestAvailable) { optionsArg = { version: npmPackage.getBestMatchingVersion('*')