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

Commit 544429ab by Mick Hansen

fix(postgres/query-generator): fix issue introduced by missing pgDataTypeMapping…

… in changeColumnQuery
1 parent ea52cb9d
Showing with 2 additions and 2 deletions
......@@ -212,8 +212,8 @@ module.exports = (function() {
});
}
if (definition.match(/^ENUM\(/)) {
query = this.pgEnum(tableName, attributeName, definition) + query;
if (attributes[attributeName].match(/^ENUM\(/)) {
query = this.pgEnum(tableName, attributeName, attributes[attributeName]) + query;
definition = definition.replace(/^ENUM\(.+\)/, this.quoteIdentifier('enum_' + tableName + '_' + attributeName));
definition += ' USING (' + this.quoteIdentifier(attributeName) + '::' + this.quoteIdentifier(definition) + ')';
}
......
Markdown is supported
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!