From 5a87e435b2e28be82ba2d637941bcb440871ea73 Mon Sep 17 00:00:00 2001 From: Jason Venable Date: Mon, 4 May 2020 23:08:14 -0400 Subject: [PATCH] Fix more typos --- index.ts | 10 +++++----- test/unit-tests/index.test.ts | 4 ++-- 2 files changed, 7 insertions(+), 7 deletions(-) diff --git a/index.ts b/index.ts index 96a48ee6..535eaf84 100644 --- a/index.ts +++ b/index.ts @@ -98,7 +98,7 @@ class ServerlessCustomDomain { } } catch (err) { this.logIfDebug(err, domain.givenDomainName); - throw new Error(`Error: Unable to craete domain ${domain.givenDomainName}`); + throw new Error(`Error: Unable to create domain ${domain.givenDomainName}`); } })); } @@ -238,7 +238,7 @@ class ServerlessCustomDomain { this.route53 = new this.serverless.providers.aws.sdk.Route53(credentials); this.cloudformation = new this.serverless.providers.aws.sdk.CloudFormation(credentials); - // Loop over the domain configurations and popluates the domains array with DomainConfigs + // Loop over the domain configurations and populate the domains array with DomainConfigs this.domains = []; // If the key of the item in config is an api type it is using per api type domain structure @@ -248,7 +248,7 @@ class ServerlessCustomDomain { this.serverless.service.custom.customDomain[configApiType].apiType = configApiType; this.domains.push(new DomainConfig(this.serverless.service.custom.customDomain[configApiType])); } else { - throw Error(`Error: Invalud API Type, ${configApiType}`); + throw Error(`Error: Invalid API Type, ${configApiType}`); } } } else { // Default to single domain config @@ -266,7 +266,7 @@ class ServerlessCustomDomain { this.acm = new this.serverless.providers.aws.sdk.ACM(acmCredentials); } - // Validate the domain configuraitons + // Validate the domain configurations this.validateDomainConfigs(); } @@ -309,7 +309,7 @@ class ServerlessCustomDomain { return domain.certificateArn; } - let certificateArn; // The arn of the choosen certificate + let certificateArn; // The arn of the selected certificate let certificateName = domain.certificateName; // The certificate name diff --git a/test/unit-tests/index.test.ts b/test/unit-tests/index.test.ts index cf310f96..803a2e61 100644 --- a/test/unit-tests/index.test.ts +++ b/test/unit-tests/index.test.ts @@ -337,8 +337,8 @@ describe("Custom Domain Plugin", () => { plugin.addOutputs(dc); - const cfTemplat = plugin.serverless.service.provider.compiledCloudFormationTemplate.Outputs; - expect(cfTemplat).to.not.equal(undefined); + const cfTemplate = plugin.serverless.service.provider.compiledCloudFormationTemplate.Outputs; + expect(cfTemplate).to.not.equal(undefined); }); it("(none) is added if basepath is an empty string", async () => {