alterColumn('{{%accounts}}', 'lang', $this->string()->notNull()->defaultValue('en')); } public function safeDown() { $this->alterColumn('{{%accounts}}', 'lang', $this->string(5)->notNull()->defaultValue('en')); } }