Skip to content

Commit 4ce83d0

Browse files
committed
fix assert_is_migrated_storage
1 parent cfb8e23 commit 4ce83d0

File tree

1 file changed

+2
-1
lines changed

1 file changed

+2
-1
lines changed

linera-storage/src/migration.rs

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -197,9 +197,10 @@ where
197197
Ok(None)
198198
}
199199

200+
/// Assert that the storage is at the last version (or not yet initialized).
200201
pub async fn assert_is_migrated_storage(&self) -> Result<(), ViewError> {
201202
let state = self.get_storage_state().await?;
202-
assert!(matches!(state, Some(SchemaVersion::Version1)));
203+
assert!(matches!(state, None | Some(SchemaVersion::Version1)));
203204
Ok(())
204205
}
205206
}

0 commit comments

Comments
 (0)