不要怂,就是干,撸起袖子干!

Commit 07b1dfd6 by Mick Hansen

fix: options.through possible not being defined in BTM

1 parent 2247a16f
Showing with 2 additions and 0 deletions
...@@ -120,6 +120,8 @@ module.exports = (function() { ...@@ -120,6 +120,8 @@ module.exports = (function() {
*/ */
if (this.through.model === true) { if (this.through.model === true) {
this.through.model = this.combinedTableName; this.through.model = this.combinedTableName;
if (!this.options.through) this.options.through = {};
this.options.through.model = this.through.model;
} }
/* /*
......
Markdown is supported
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!