Fixing issue with aliasing.
This commit is contained in:
parent
e76dc01859
commit
5c4dc0dc83
|
@ -372,9 +372,9 @@ class InternalBuilder {
|
||||||
}
|
}
|
||||||
for (let [key, relationships] of Object.entries(tableSets)) {
|
for (let [key, relationships] of Object.entries(tableSets)) {
|
||||||
const { toTable, throughTable } = JSON.parse(key)
|
const { toTable, throughTable } = JSON.parse(key)
|
||||||
const toAlias = aliases[toTable],
|
const toAlias = aliases[toTable] || toTable,
|
||||||
throughAlias = aliases[throughTable],
|
throughAlias = aliases[throughTable] || throughTable,
|
||||||
fromAlias = aliases[fromTable]
|
fromAlias = aliases[fromTable] || fromTable
|
||||||
let toTableWithSchema = this.tableNameWithSchema(toTable, {
|
let toTableWithSchema = this.tableNameWithSchema(toTable, {
|
||||||
alias: toAlias,
|
alias: toAlias,
|
||||||
schema,
|
schema,
|
||||||
|
|
Loading…
Reference in New Issue