diff options
| -rw-r--r-- | makima/src/db/repository.rs | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/makima/src/db/repository.rs b/makima/src/db/repository.rs index ed56fff..63493b9 100644 --- a/makima/src/db/repository.rs +++ b/makima/src/db/repository.rs @@ -5309,7 +5309,7 @@ pub async fn create_directive_chain( total_steps: i32, ) -> Result<DirectiveChain, sqlx::Error> { // Get next generation number - let next_gen: (i64,) = sqlx::query_as( + let next_gen: (i32,) = sqlx::query_as( "SELECT COALESCE(MAX(generation), 0) + 1 FROM directive_chains WHERE directive_id = $1", ) .bind(directive_id) @@ -5324,7 +5324,7 @@ pub async fn create_directive_chain( "#, ) .bind(directive_id) - .bind(next_gen.0 as i32) + .bind(next_gen.0) .bind(name) .bind(description) .bind(rationale) |
