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

Commit f1762fd8 by Robert Kieffer Committed by Sushant

Clone defaultScope so it doesn't get overwritten in Model#init (#6971)

1 parent 964999dd
Showing with 1 additions and 3 deletions
...@@ -700,9 +700,7 @@ class Model { ...@@ -700,9 +700,7 @@ class Model {
const globalOptions = this.sequelize.options; const globalOptions = this.sequelize.options;
if (globalOptions.define) { options = Utils.merge(_.cloneDeep(globalOptions.define), options);
options = Utils.merge(globalOptions.define, options);
}
if (!options.modelName) { if (!options.modelName) {
options.modelName = this.name; options.modelName = this.name;
......
Markdown is supported
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!