Skip to content

Commit 51b7943

Browse files
committed
fix typo though → through
a minor typo I found
1 parent 84a0538 commit 51b7943

File tree

4 files changed

+6
-6
lines changed

4 files changed

+6
-6
lines changed

lib/models/BaseSequelize.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -16,7 +16,7 @@ import {ISequelizeAssociation} from "../interfaces/ISequelizeAssociation";
1616
*/
1717
export abstract class BaseSequelize {
1818

19-
thoughMap: { [through: string]: any } = {};
19+
throughMap: { [through: string]: any } = {};
2020
_: { [modelName: string]: (typeof Model) } = {};
2121

2222
static extend(target: any): void {

lib/models/v3/Sequelize.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -15,7 +15,7 @@ export class Sequelize extends SequelizeOrigin implements BaseSequelize {
1515
// to fix "$1" called with something that's not an instance of Sequelize.Model
1616
Model: any = Function;
1717

18-
thoughMap: { [through: string]: any } = {};
18+
throughMap: { [through: string]: any } = {};
1919
_: { [modelName: string]: typeof Model } = {};
2020
init: (config: ISequelizeConfig) => void;
2121
addModels: (models: Array<typeof Model> | string[]) => void;

lib/models/v4/Sequelize.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -11,7 +11,7 @@ let preparedConfig;
1111

1212
export class Sequelize extends OriginSequelize implements BaseSequelize {
1313

14-
thoughMap: {[through: string]: any} = {};
14+
throughMap: {[through: string]: any} = {};
1515
_: {[modelName: string]: typeof Model} = {};
1616
init: (config: ISequelizeConfig) => void;
1717
addModels: (models: Array<typeof Model>|string[]) => void;

lib/services/association.ts

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -227,12 +227,12 @@ export function processAssociation(sequelize: BaseSequelize,
227227
export function getThroughClass(sequelize: BaseSequelize,
228228
association: ISequelizeAssociation): any {
229229
if (association.through) {
230-
if (!sequelize.thoughMap[association.through]) {
230+
if (!sequelize.throughMap[association.through]) {
231231
const throughModel = sequelize.getThroughModel(association.through);
232232
sequelize.addModels([throughModel]);
233-
sequelize.thoughMap[association.through] = throughModel;
233+
sequelize.throughMap[association.through] = throughModel;
234234
}
235-
return sequelize.thoughMap[association.through];
235+
return sequelize.throughMap[association.through];
236236
}
237237
return (association.throughClassGetter as () => typeof Model)();
238238
}

0 commit comments

Comments
 (0)