bugfix: Prevent a panic and return a reasonable default

This commit is contained in:
Mike Dilger 2024-06-18 09:22:44 +12:00
parent 3207baa41a
commit 8e73ddaa21

View File

@ -75,7 +75,10 @@ impl Feed {
pub(crate) fn current_anchor(&self) -> Unixtime {
let anchor_key = self.current_feed_kind.read().anchor_key();
*self.feed_anchors.get(&anchor_key).unwrap()
*self
.feed_anchors
.get(&anchor_key)
.unwrap_or(Unixtime::now().unwrap())
}
fn unlisten(&self) {