Skip to content

Commit

Permalink
typo
Browse files Browse the repository at this point in the history
  • Loading branch information
Li0k committed Nov 4, 2024
1 parent b4b6b41 commit 40e8f25
Showing 1 changed file with 10 additions and 1 deletion.
11 changes: 10 additions & 1 deletion src/storage/src/hummock/local_version/pinned_version.rs
Original file line number Diff line number Diff line change
Expand Up @@ -131,7 +131,16 @@ impl PinnedVersion {
}

fn levels_by_compaction_groups_id(&self, compaction_group_id: CompactionGroupId) -> &Levels {
self.version.levels.get(&compaction_group_id).unwrap()
self.version
.levels
.get(&compaction_group_id)
.unwrap_or_else(|| {
panic!(
"levels for compaction group {} not found in version {}",
compaction_group_id,
self.id()
)
})
}

pub fn levels(&self, table_id: TableId) -> impl Iterator<Item = &Level> {
Expand Down

0 comments on commit 40e8f25

Please sign in to comment.