@strapi/database 5.0.3 → 5.0.5
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/dist/index.mjs
CHANGED
|
@@ -1275,7 +1275,7 @@ const createSchemaDiff = (db) => {
|
|
|
1275
1275
|
const hasChangedStatus = (diff) => diff.status === statuses.CHANGED;
|
|
1276
1276
|
const diffIndexes = (oldIndex, index2) => {
|
|
1277
1277
|
const changes = [];
|
|
1278
|
-
if (
|
|
1278
|
+
if (_.xor(oldIndex.columns, index2.columns).length > 0) {
|
|
1279
1279
|
changes.push("columns");
|
|
1280
1280
|
}
|
|
1281
1281
|
if (oldIndex.type && index2.type && _.toLower(oldIndex.type) !== _.toLower(index2.type)) {
|
|
@@ -6401,6 +6401,7 @@ const createPublishedAtColumn = async (db, tableName) => {
|
|
|
6401
6401
|
await db.schema.alterTable(tableName, (table) => {
|
|
6402
6402
|
table.string("published_at");
|
|
6403
6403
|
});
|
|
6404
|
+
await db(tableName).update({ published_at: /* @__PURE__ */ new Date() });
|
|
6404
6405
|
};
|
|
6405
6406
|
const createdPublishedAt = {
|
|
6406
6407
|
name: "5.0.0-04-created-published-at",
|