Compile result of .defaultsTo(null) to "default null", not "default 'null'"

This commit is contained in:
Kris Reeves 2014-08-25 17:14:58 -04:00
parent 289c661152
commit 3d3e4036bb

View File

@ -110,6 +110,8 @@ ColumnCompiler.prototype.notNullable = function() {
ColumnCompiler.prototype.defaultTo = function(value) {
if (value === void 0) {
return '';
} else if (value === null) {
value = "null";
} else if (value instanceof Raw) {
value = value.toQuery();
} else if (this.type === 'bool') {