Explain runtime invariants and avoid redundant unwraps

This commit is contained in:
Samuel Onoja committed 2026-10-22 01:28:03 +01:00
1 parent 34f2f07301
commit 1b51ba83b4
116 files changed
+1643 -515

No files matched your search

+4 -1
View File
@@ -146,7 +146,10 @@ impl PortalSession {
pub(crate) fn begin_owned_query(&mut self, owner: u64) -> u32 {
let token = self.begin_query();
self.query.as_mut().unwrap().owner = Some(owner);
self.query
.as_mut()
.expect("begin_query installs the query before setting its owner")
.owner = Some(owner);
token
}