"use strict";
module.exports = {
    async up (db, client) {
        const session = client.startSession();
        try {
            await session.withTransaction(async ()=>{
                const dbCollection = db.collection("printers");
                await dbCollection.updateMany({}, {
                    $rename: {
                        settingsApperance: "settingsAppearance"
                    }
                });
                await dbCollection.updateMany({}, {
                    $rename: {
                        apikey: "apiKey"
                    }
                });
            });
        } finally{
            await session.endSession();
        }
    },
    async down (db, client) {
        const session = client.startSession();
        try {
            await session.withTransaction(async ()=>{
                const dbCollection = db.collection("printers");
                await dbCollection.updateMany({}, {
                    $rename: {
                        settingsAppearance: "settingsApperance"
                    }
                });
                await dbCollection.updateMany({}, {
                    $rename: {
                        apiKey: "apikey"
                    }
                });
            });
        } finally{
            await session.endSession();
        }
    }
};

//# sourceMappingURL=20210713120034-printers-settingsapperance-apikey.js.map