From 1377c2b5ebf3575040ea007d8cc807effcc339e7 Mon Sep 17 00:00:00 2001 From: Eric King Date: Sun, 28 Apr 2024 19:55:04 -0500 Subject: [PATCH] chore: fixed spelling issues --- src/packagers/index.ts | 10 +++++----- src/tests/packagers/npm.test.ts | 2 +- 2 files changed, 6 insertions(+), 6 deletions(-) diff --git a/src/packagers/index.ts b/src/packagers/index.ts index e3aa1759..6ecf2644 100644 --- a/src/packagers/index.ts +++ b/src/packagers/index.ts @@ -13,7 +13,7 @@ import type EsbuildServerlessPlugin from '../index'; import type { PackagerId, PackagerOptions } from '../types'; import type { Packager } from './packager'; -const packagerFactories: Record Promise> = { +const packagerFactories: Record Promise> = { async npm() { const { NPM } = await import('./npm'); @@ -24,10 +24,10 @@ const packagerFactories: Record return new Pnpm(); }, - async yarn(packgerOptions) { + async yarn(packagerOptions) { const { Yarn } = await import('./yarn'); - return new Yarn(packgerOptions); + return new Yarn(packagerOptions); }, }; @@ -43,7 +43,7 @@ export const getPackager = memoizeWith( async function ( this: EsbuildServerlessPlugin, packagerId: PackagerId, - packgerOptions: PackagerOptions + packagerOptions: PackagerOptions ): Promise { this.log.debug(`Trying to create packager: ${packagerId}`); @@ -53,7 +53,7 @@ export const getPackager = memoizeWith( throw new this.serverless.classes.Error(`Could not find packager '${packagerId}'`); } - const packager = await packagerFactories[packagerId](packgerOptions); + const packager = await packagerFactories[packagerId](packagerOptions); this.log.debug(`Packager created: ${packagerId}`); diff --git a/src/tests/packagers/npm.test.ts b/src/tests/packagers/npm.test.ts index 2804dbe2..13b024f5 100644 --- a/src/tests/packagers/npm.test.ts +++ b/src/tests/packagers/npm.test.ts @@ -416,7 +416,7 @@ describe('NPM Packager', () => { expect(v7dependencies).toStrictEqual(expectedResult); }); - it('should create the same dependency tree which handles deduping for both npmv6 and npmv7', async () => { + it('should create the same dependency tree which handles deduping for both npm v6 and v7', async () => { const v6depsList: NpmV6Deps = { name: 'serverless-example', version: '1.0.0',