"use strict";
Object.defineProperty(exports, "__esModule", { value: true });
exports.AddCodeToNetworks1722480000000 = void 0;
const typeorm_1 = require("typeorm");
class AddCodeToNetworks1722480000000 {
    async up(queryRunner) {
        const table = await queryRunner.getTable('networks');
        if (table?.findColumnByName('code')) {
            return;
        }
        await queryRunner.addColumn('networks', new typeorm_1.TableColumn({
            name: 'code',
            type: 'varchar',
            length: '255',
            isNullable: false,
            default: "''",
        }));
    }
    async down(queryRunner) {
        const table = await queryRunner.getTable('networks');
        if (table?.findColumnByName('code')) {
            await queryRunner.dropColumn('networks', 'code');
        }
    }
}
exports.AddCodeToNetworks1722480000000 = AddCodeToNetworks1722480000000;
//# sourceMappingURL=1722480000000-AddCodeToNetworks.js.map