Applies the V3 additions on top of V2 (complexity columns).
(conn: &Connection)
| 407 | |
| 408 | /// Applies the V3 additions on top of V2 (complexity columns). |
| 409 | async fn apply_v3(conn: &Connection) { |
| 410 | conn.execute_batch( |
| 411 | "ALTER TABLE nodes ADD COLUMN branches INTEGER NOT NULL DEFAULT 0; |
| 412 | ALTER TABLE nodes ADD COLUMN loops INTEGER NOT NULL DEFAULT 0; |
| 413 | ALTER TABLE nodes ADD COLUMN returns INTEGER NOT NULL DEFAULT 0; |
| 414 | ALTER TABLE nodes ADD COLUMN max_nesting INTEGER NOT NULL DEFAULT 0;", |
| 415 | ) |
| 416 | .await |
| 417 | .expect("failed to apply v3"); |
| 418 | set_user_version(conn, 3).await; |
| 419 | } |
| 420 | |
| 421 | /// Applies the V4 additions on top of V3 (safety metric columns). |
| 422 | async fn apply_v4(conn: &Connection) { |
no test coverage detected