Skip to content

Commit

Permalink
Merge pull request #9806 from chunghha/fix_typos
Browse files Browse the repository at this point in the history
chore: typo fix
  • Loading branch information
kamilmysliwiec committed Jun 20, 2022
2 parents f3060a0 + bf73768 commit ff46a1c
Show file tree
Hide file tree
Showing 16 changed files with 18 additions and 18 deletions.
2 changes: 1 addition & 1 deletion packages/common/cache/interfaces/cache-module.interface.ts
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ import { CacheManagerOptions } from './cache-manager.interface';
export type CacheModuleOptions<
StoreConfig extends Record<any, any> = Record<string, any>,
> =
// Store-specfic configuration takes precedence over cache module options due
// Store-specific configuration takes precedence over cache module options due
// to how `createCacheManager` is implemented.
CacheManagerOptions &
StoreConfig & {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -72,7 +72,7 @@ export interface INestApplicationContext {
enableShutdownHooks(signals?: ShutdownSignal[] | string[]): this;

/**
* Initalizes the Nest application.
* Initializes the Nest application.
* Calls the Nest lifecycle events.
* It isn't mandatory to call this method directly.
*
Expand Down
2 changes: 1 addition & 1 deletion packages/common/interfaces/version-options.interface.ts
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@ export type VersionValue =
export interface VersionOptions {
/**
* Specifies an optional API Version. When configured, methods
* withing the controller will only be routed if the request version
* within the controller will only be routed if the request version
* matches the specified value.
*
* Supported only by HTTP-based applications (does not apply to non-HTTP microservices).
Expand Down
4 changes: 2 additions & 2 deletions packages/common/services/console-logger.service.ts
Original file line number Diff line number Diff line change
Expand Up @@ -188,7 +188,7 @@ export class ConsoleLogger implements LoggerService {
const contextMessage = context ? yellow(`[${context}] `) : '';
const timestampDiff = this.updateAndGetTimestampDiff();
const formattedLogLevel = logLevel.toUpperCase().padStart(7, ' ');
const formatedMessage = this.formatMessage(
const formattedMessage = this.formatMessage(
logLevel,
message,
pidMessage,
Expand All @@ -197,7 +197,7 @@ export class ConsoleLogger implements LoggerService {
timestampDiff,
);

process[writeStreamType ?? 'stdout'].write(formatedMessage);
process[writeStreamType ?? 'stdout'].write(formattedMessage);
});
}

Expand Down
4 changes: 2 additions & 2 deletions packages/common/test/file-stream/streamable-file.spec.ts
Original file line number Diff line number Diff line change
Expand Up @@ -4,14 +4,14 @@ import { StreamableFile } from '../../file-stream';

describe('StreamableFile', () => {
describe('when input is a readable stream', () => {
it('should assing it to a stream class property', () => {
it('should assign it to a stream class property', () => {
const stream = new Readable();
const streamableFile = new StreamableFile(stream);
expect(streamableFile.getStream()).to.equal(stream);
});
});
describe('when input is an object with "pipe" method', () => {
it('should assing it to a stream class property', () => {
it('should assign it to a stream class property', () => {
const stream = { pipe: () => {} };
const streamableFile = new StreamableFile(stream as any);
expect(streamableFile.getStream()).to.equal(stream);
Expand Down
2 changes: 1 addition & 1 deletion packages/core/injector/lazy-module-loader.ts
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,7 @@ export class LazyModuleLoader {
);
if (moduleInstances.length === 0) {
// The module has been loaded already. In this case, we must
// retrieve a module reference from the exising container.
// retrieve a module reference from the existing container.
const { token } = await this.moduleCompiler.compile(
moduleClassOrDynamicDefinition,
);
Expand Down
2 changes: 1 addition & 1 deletion packages/core/test/injector/injector.spec.ts
Original file line number Diff line number Diff line change
Expand Up @@ -595,7 +595,7 @@ describe('Injector', () => {
});
});

describe('when instanceWraper has async property', () => {
describe('when instanceWrapper has async property', () => {
it('should await instance', async () => {
sinon.stub(injector, 'loadProvider').callsFake(() => null);

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ import { InternalCoreModule } from '../../injector/internal-core-module';
import { InternalCoreModuleFactory } from '../../injector/internal-core-module-factory';

describe('InternalCoreModuleFactory', () => {
it('should return the interal core module definition', () => {
it('should return the internal core module definition', () => {
const moduleDefinition = InternalCoreModuleFactory.create(
new NestContainer(),
null,
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -356,7 +356,7 @@ data: test
request as unknown as IncomingMessage,
);
} catch {
// Wether an error is thrown or not
// Whether an error is thrown or not
// is not relevant, so long as
// result is not called
}
Expand Down
2 changes: 1 addition & 1 deletion packages/microservices/ctx-host/mqtt.context.ts
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@ export class MqttContext extends BaseRpcContext<MqttContextArgs> {
}

/**
* Returns the refernce to the original MQTT packet.
* Returns the reference to the original MQTT packet.
*/
getPacket() {
return this.args[1];
Expand Down
2 changes: 1 addition & 1 deletion packages/microservices/test/client/client-mqtt.spec.ts
Original file line number Diff line number Diff line change
Expand Up @@ -110,7 +110,7 @@ describe('ClientMqtt', () => {
it('should unsubscribe to response pattern name', () => {
expect(unsubscribeSpy.calledWith(channel)).to.be.true;
});
it('should remove callback from routin map', () => {
it('should remove callback from routing map', () => {
expect(client['routingMap'].has(id)).to.be.false;
});
});
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,7 @@ describe('KafkaResponseDeserializer', () => {
});
});
describe('when is disposed header is present', () => {
it('should return an objet with "isDisposed"', () => {
it('should return an object with "isDisposed"', () => {
const value = 'test';
const packet = instance.deserialize({
headers: {
Expand Down
2 changes: 1 addition & 1 deletion packages/microservices/test/listeners-controller.spec.ts
Original file line number Diff line number Diff line change
Expand Up @@ -247,7 +247,7 @@ describe('ListenersController', () => {
});

describe('assignClientToInstance', () => {
it('should assing client to instance', () => {
it('should assign client to instance', () => {
const propertyKey = 'key';
const object = {};
const client = { test: true };
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,7 @@ describe('MqttRecordSerializer', () => {
data: { value: 'string' },
});
});
it('should act as an indentity function if msg is not an instance of MqttRecord class', () => {
it('should act as an identity function if msg is not an instance of MqttRecord class', () => {
const packet = {
data: { random: true },
};
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,7 @@ describe('RmqRecordSerializer', () => {
});
});

it('should act as an indentity function if msg is not an instance of RmqRecord class', () => {
it('should act as an identity function if msg is not an instance of RmqRecord class', () => {
const packet = {
data: { random: true },
};
Expand Down
2 changes: 1 addition & 1 deletion packages/microservices/test/server/server-mqtt.spec.ts
Original file line number Diff line number Diff line change
Expand Up @@ -175,7 +175,7 @@ describe('ServerMqtt', () => {
});
describe('getRequestPattern', () => {
const test = 'test';
it(`should leave patern as it is`, () => {
it(`should leave pattern as it is`, () => {
expect(server.getRequestPattern(test)).to.equal(test);
});
});
Expand Down

0 comments on commit ff46a1c

Please sign in to comment.