Update signature for alterTable
Since alterTable is semi-public, the method now checks the arugments to make sure that it still supports the old signature that doesn't include actualFks
This commit is contained in:
parent
d461d07f34
commit
0b04d461e4
|
@ -116,6 +116,12 @@ function mixinMigration(MySQL, mysql) {
|
|||
};
|
||||
|
||||
MySQL.prototype.alterTable = function(model, actualFields, actualIndexes, actualFks, done, checkOnly) {
|
||||
//if this is using an old signature, then grab the correct callback and check boolean
|
||||
if ('function' == typeof actualFks && typeof done !== 'function') {
|
||||
checkOnly = done || false;
|
||||
done = actualFks;
|
||||
}
|
||||
|
||||
var self = this;
|
||||
var m = this.getModelDefinition(model);
|
||||
var propNames = Object.keys(m.properties).filter(function(name) {
|
||||
|
|
Loading…
Reference in New Issue