From 6381c8d519742c445db7fb20682ea40464d82665 Mon Sep 17 00:00:00 2001 From: Piotr Kuczynski Date: Sun, 9 Nov 2025 21:57:31 +0100 Subject: [PATCH] docs: fix typos in the js documentation (#11754) --- src/decorator/tree/TreeChildren.ts | 2 +- src/decorator/tree/TreeParent.ts | 2 +- src/driver/aurora-mysql/AuroraMysqlQueryRunner.ts | 4 ++-- src/driver/mongodb/MongoQueryRunner.ts | 10 +++++----- src/driver/mongodb/typings.ts | 2 +- src/driver/mysql/MysqlQueryRunner.ts | 4 ++-- src/driver/oracle/OracleQueryRunner.ts | 4 ++-- src/driver/sap/SapQueryRunner.ts | 2 +- src/driver/spanner/SpannerQueryRunner.ts | 2 +- .../sqlite-abstract/AbstractSqliteQueryRunner.ts | 4 ++-- src/driver/sqlserver/SqlServerQueryRunner.ts | 2 +- src/query-runner/QueryRunner.ts | 2 +- test/functional/entity-schema/uniques/uniques-basic.ts | 2 +- 13 files changed, 21 insertions(+), 21 deletions(-) diff --git a/src/decorator/tree/TreeChildren.ts b/src/decorator/tree/TreeChildren.ts index 650d59422..1dc5d9275 100644 --- a/src/decorator/tree/TreeChildren.ts +++ b/src/decorator/tree/TreeChildren.ts @@ -3,7 +3,7 @@ import { RelationMetadataArgs } from "../../metadata-args/RelationMetadataArgs" import { RelationOptions } from "../options/RelationOptions" /** - * Marks a entity property as a children of the tree. + * Marks an entity property as a children of the tree. * "Tree children" will contain all children (bind) of this entity. */ export function TreeChildren(options?: { diff --git a/src/decorator/tree/TreeParent.ts b/src/decorator/tree/TreeParent.ts index ccf5b1a98..57708c5ce 100644 --- a/src/decorator/tree/TreeParent.ts +++ b/src/decorator/tree/TreeParent.ts @@ -4,7 +4,7 @@ import { OnDeleteType } from "../../metadata/types/OnDeleteType" import { RelationOptions } from "../options/RelationOptions" /** - * Marks a entity property as a parent of the tree. + * Marks an entity property as a parent of the tree. * "Tree parent" indicates who owns (is a parent) of this entity in tree structure. */ export function TreeParent(options?: { diff --git a/src/driver/aurora-mysql/AuroraMysqlQueryRunner.ts b/src/driver/aurora-mysql/AuroraMysqlQueryRunner.ts index 3847c7608..89024ce67 100644 --- a/src/driver/aurora-mysql/AuroraMysqlQueryRunner.ts +++ b/src/driver/aurora-mysql/AuroraMysqlQueryRunner.ts @@ -1608,7 +1608,7 @@ export class AuroraMysqlQueryRunner } /** - * Drops an unique constraint. + * Drops a unique constraint. */ async dropUniqueConstraint( tableOrName: Table | string, @@ -1620,7 +1620,7 @@ export class AuroraMysqlQueryRunner } /** - * Drops an unique constraints. + * Drops a unique constraints. */ async dropUniqueConstraints( tableOrName: Table | string, diff --git a/src/driver/mongodb/MongoQueryRunner.ts b/src/driver/mongodb/MongoQueryRunner.ts index 98ec2bc7d..d6a2b83a1 100644 --- a/src/driver/mongodb/MongoQueryRunner.ts +++ b/src/driver/mongodb/MongoQueryRunner.ts @@ -533,15 +533,15 @@ export class MongoQueryRunner implements QueryRunner { } /** - * For MongoDB database we don't create connection, because its single connection already created by a driver. + * For MongoDB database we don't create a connection because its single connection already created by a driver. */ async connect(): Promise {} /** - * For MongoDB database we don't release connection, because its single connection. + * For MongoDB database we don't release the connection because it is a single connection. */ async release(): Promise { - // releasing connection are not supported by mongodb driver, so simply don't do anything here + // the mongodb driver does not support releasing connection, so simply don't do anything here } /** @@ -983,7 +983,7 @@ export class MongoQueryRunner implements QueryRunner { } /** - * Drops an unique constraint. + * Drops a unique constraint. */ async dropUniqueConstraint( tableOrName: Table | string, @@ -995,7 +995,7 @@ export class MongoQueryRunner implements QueryRunner { } /** - * Drops an unique constraints. + * Drops unique constraints. */ async dropUniqueConstraints( tableOrName: Table | string, diff --git a/src/driver/mongodb/typings.ts b/src/driver/mongodb/typings.ts index 4fb63d974..01b25ee1f 100644 --- a/src/driver/mongodb/typings.ts +++ b/src/driver/mongodb/typings.ts @@ -2755,7 +2755,7 @@ export declare interface CreateIndexesOptions extends Omit { /** Creates the index in the background, yielding whenever possible. */ background?: boolean - /** Creates an unique index. */ + /** Creates a unique index. */ unique?: boolean /** Override the autogenerated index name (useful if the resulting name is larger than 128 bytes) */ name?: string diff --git a/src/driver/mysql/MysqlQueryRunner.ts b/src/driver/mysql/MysqlQueryRunner.ts index 6e2e9546b..620ab7d22 100644 --- a/src/driver/mysql/MysqlQueryRunner.ts +++ b/src/driver/mysql/MysqlQueryRunner.ts @@ -1994,7 +1994,7 @@ export class MysqlQueryRunner extends BaseQueryRunner implements QueryRunner { } /** - * Drops an unique constraint. + * Drops a unique constraint. */ async dropUniqueConstraint( tableOrName: Table | string, @@ -2006,7 +2006,7 @@ export class MysqlQueryRunner extends BaseQueryRunner implements QueryRunner { } /** - * Drops an unique constraints. + * Drops a unique constraints. */ async dropUniqueConstraints( tableOrName: Table | string, diff --git a/src/driver/oracle/OracleQueryRunner.ts b/src/driver/oracle/OracleQueryRunner.ts index 62af61291..141f2bf5e 100644 --- a/src/driver/oracle/OracleQueryRunner.ts +++ b/src/driver/oracle/OracleQueryRunner.ts @@ -1901,7 +1901,7 @@ export class OracleQueryRunner extends BaseQueryRunner implements QueryRunner { } /** - * Drops an unique constraint. + * Drops a unique constraint. */ async dropUniqueConstraint( tableOrName: Table | string, @@ -1925,7 +1925,7 @@ export class OracleQueryRunner extends BaseQueryRunner implements QueryRunner { } /** - * Creates an unique constraints. + * Creates a unique constraints. */ async dropUniqueConstraints( tableOrName: Table | string, diff --git a/src/driver/sap/SapQueryRunner.ts b/src/driver/sap/SapQueryRunner.ts index 9920ffe76..20b5742fd 100644 --- a/src/driver/sap/SapQueryRunner.ts +++ b/src/driver/sap/SapQueryRunner.ts @@ -2145,7 +2145,7 @@ export class SapQueryRunner extends BaseQueryRunner implements QueryRunner { } /** - * Drops an unique constraints. + * Drops unique constraints. */ async dropUniqueConstraints( tableOrName: Table | string, diff --git a/src/driver/spanner/SpannerQueryRunner.ts b/src/driver/spanner/SpannerQueryRunner.ts index 4c1a73b70..b036a251a 100644 --- a/src/driver/spanner/SpannerQueryRunner.ts +++ b/src/driver/spanner/SpannerQueryRunner.ts @@ -1145,7 +1145,7 @@ export class SpannerQueryRunner extends BaseQueryRunner implements QueryRunner { } /** - * Creates new check constraint. + * Creates a new check constraint. */ async createCheckConstraint( tableOrName: Table | string, diff --git a/src/driver/sqlite-abstract/AbstractSqliteQueryRunner.ts b/src/driver/sqlite-abstract/AbstractSqliteQueryRunner.ts index 9cd9d5d27..c4578b2e4 100644 --- a/src/driver/sqlite-abstract/AbstractSqliteQueryRunner.ts +++ b/src/driver/sqlite-abstract/AbstractSqliteQueryRunner.ts @@ -861,7 +861,7 @@ export abstract class AbstractSqliteQueryRunner } /** - * Drops an unique constraint. + * Drops a unique constraint. */ async dropUniqueConstraint( tableOrName: Table | string, @@ -882,7 +882,7 @@ export abstract class AbstractSqliteQueryRunner } /** - * Creates an unique constraints. + * Creates a unique constraints. */ async dropUniqueConstraints( tableOrName: Table | string, diff --git a/src/driver/sqlserver/SqlServerQueryRunner.ts b/src/driver/sqlserver/SqlServerQueryRunner.ts index 46dac1a2a..0074d9322 100644 --- a/src/driver/sqlserver/SqlServerQueryRunner.ts +++ b/src/driver/sqlserver/SqlServerQueryRunner.ts @@ -2311,7 +2311,7 @@ export class SqlServerQueryRunner } /** - * Drops an unique constraints. + * Drops unique constraints. */ async dropUniqueConstraints( tableOrName: Table | string, diff --git a/src/query-runner/QueryRunner.ts b/src/query-runner/QueryRunner.ts index a88f4662d..7566c6f1e 100644 --- a/src/query-runner/QueryRunner.ts +++ b/src/query-runner/QueryRunner.ts @@ -385,7 +385,7 @@ export interface QueryRunner { ): Promise /** - * Drops an unique constraint. + * Drops a unique constraint. */ dropUniqueConstraint( table: Table | string, diff --git a/test/functional/entity-schema/uniques/uniques-basic.ts b/test/functional/entity-schema/uniques/uniques-basic.ts index 998e718b2..07b27a2a6 100644 --- a/test/functional/entity-schema/uniques/uniques-basic.ts +++ b/test/functional/entity-schema/uniques/uniques-basic.ts @@ -20,7 +20,7 @@ describe("entity-schema > uniques", () => { beforeEach(() => reloadTestingDatabases(connections)) after(() => closeTestingConnections(connections)) - it("should create an unique constraint with 2 columns", () => + it("should create a unique constraint with 2 columns", () => Promise.all( connections.map(async (connection) => { const queryRunner = connection.createQueryRunner()