Fix #521 by converting content fields to LONGTEXT in MySQL, to prevent truncation of data.

This commit is contained in:
Claudius Coenen 2017-10-16 10:12:39 +02:00
parent 5ce8f40eac
commit cc49ce55c8
3 changed files with 20 additions and 4 deletions

View file

@ -58,7 +58,7 @@ module.exports = function (sequelize, DataTypes) {
defaultValue: Sequelize.UUIDV4
},
patch: {
type: DataTypes.TEXT,
type: DataTypes.TEXT('long'),
get: function () {
return sequelize.processData(this.getDataValue('patch'), '')
},
@ -67,7 +67,7 @@ module.exports = function (sequelize, DataTypes) {
}
},
lastContent: {
type: DataTypes.TEXT,
type: DataTypes.TEXT('long'),
get: function () {
return sequelize.processData(this.getDataValue('lastContent'), '')
},
@ -76,7 +76,7 @@ module.exports = function (sequelize, DataTypes) {
}
},
content: {
type: DataTypes.TEXT,
type: DataTypes.TEXT('long'),
get: function () {
return sequelize.processData(this.getDataValue('content'), '')
},