alapa
Version:
A cutting-edge web development framework designed to revolutionize the way developers build modern web applications.
21 lines (20 loc) • 604 B
JavaScript
Object.defineProperty(exports, "__esModule", { value: true });
exports.TextColumn = TextColumn;
const typeorm_1 = require("typeorm");
function TextColumn(type = "text", options) {
return function (object, propertyName) {
const databaseType = process.env.DATABASE_TYPES;
if (databaseType === "postgres") {
if (type === "text") {
//change type
}
}
(0, typeorm_1.Column)({
nullable: true,
type: type,
default: "",
...options,
})(object, propertyName);
};
}
;