diff --git a/eventsourced-postgres/src/evt_log.rs b/eventsourced-postgres/src/evt_log.rs index 039301b..9332811 100644 --- a/eventsourced-postgres/src/evt_log.rs +++ b/eventsourced-postgres/src/evt_log.rs @@ -270,7 +270,7 @@ impl EvtLog for PostgresEvtLog { let last_seq_no = self .cnn() .await? - .query_one("SELECT COALESCE(MAX(seq_no), 0) FROM evts", &[]) + .query_one("SELECT COALESCE(MAX(seq_no), 1) FROM evts", &[]) .await .map_err(Error::ExecuteQuery) .and_then(|row| { diff --git a/justfile b/justfile index 493975c..3ab403c 100644 --- a/justfile +++ b/justfile @@ -15,6 +15,9 @@ lint: test: cargo test --all-features +fix: + cargo fix --allow-dirty --allow-staged --all-features + doc: RUSTDOCFLAGS="-D warnings" cargo doc --no-deps --all-features