on main help sign in
Fix issue where `changes` had to be set for `alter_column`

Some type of changes don't require anything in `changes`, for example when changing the values of a column with `up` and `down`.

commit35a52ebd8193d6655151795f4f2cd8dc5fb0ccd3 authorfabianlindfors <fabian@flapplabs.se> dateSat 15 Jan 2022, 15:53 (5 years ago) parenta7d70f8
1 file changed+2−1
src/migrations/alter_column.rs+2−1
src/migrations/alter_column.rs+2−1
@@ -13,10 +13,11 @@ pub struct AlterColumn {
1313 pub column: String,
1414 pub up: Option<String>,
1515 pub down: Option<String>,
16+ #[serde(default)]
1617 pub changes: ColumnChanges,
1718}
1819
19−#[derive(Serialize, Deserialize, Debug)]
20+#[derive(Serialize, Deserialize, Default, Debug)]
2021pub struct ColumnChanges {
2122 pub name: Option<String>,
2223 #[serde(rename = "type")]