From b0678e6474729e6c7d4e8a8b367a1b3c20a3de20 Mon Sep 17 00:00:00 2001 From: Kononnable Date: Tue, 31 Jul 2018 22:18:14 +0200 Subject: [PATCH] fixing naming strategy bug - naming of related column in owner relation --- src/drivers/AbstractDriver.ts | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/src/drivers/AbstractDriver.ts b/src/drivers/AbstractDriver.ts index 4885515..c72895e 100644 --- a/src/drivers/AbstractDriver.ts +++ b/src/drivers/AbstractDriver.ts @@ -40,7 +40,8 @@ export abstract class AbstractDriver { column2.relations .filter(relation => { return ( - relation.ownerTable == entity.EntityName && + relation.relatedTable == + entity.EntityName && relation.ownerColumn == column.tsName ); })