@minatojs/driver-mysql
Advanced tools
Comparing version 2.0.3 to 2.0.4
@@ -86,2 +86,4 @@ "use strict"; | ||
const typename = def.split(/[ (]/)[0]; | ||
if (typename === "text") | ||
return !column.DATA_TYPE.endsWith("text"); | ||
if (typename !== column.DATA_TYPE) | ||
@@ -97,3 +99,3 @@ return true; | ||
case "json": | ||
return !!field.length && column.CHARACTER_MAXIMUM_LENGTH !== field.length; | ||
return !!field.length && !!column.CHARACTER_MAXIMUM_LENGTH && column.CHARACTER_MAXIMUM_LENGTH !== field.length; | ||
case "decimal": | ||
@@ -265,2 +267,3 @@ return column.NUMERIC_PRECISION !== field.precision || column.NUMERIC_SCALE !== field.scale; | ||
logger.info("auto updating table %c", name); | ||
console.log(operations); | ||
await this.queue(`ALTER TABLE ?? ${operations.join(", ")}`, [name]); | ||
@@ -267,0 +270,0 @@ } |
{ | ||
"name": "@minatojs/driver-mysql", | ||
"version": "2.0.3", | ||
"version": "2.0.4", | ||
"description": "MySQL Driver for Minato", | ||
@@ -5,0 +5,0 @@ "main": "lib/index.js", |
Sorry, the diff of this file is not supported yet
47716
507