state: Properly propagate errors when persisting state
This commit is contained in:
@ -59,14 +59,14 @@ impl FeedReaderStateDb {
|
||||
&self,
|
||||
uri: &str,
|
||||
dt: DateTime<Utc>
|
||||
) -> () {
|
||||
) -> Result<(), Box<dyn Error>> {
|
||||
|
||||
{
|
||||
debug!("Updating feed reader state");
|
||||
self.lock_state().insert(uri.into(), dt.timestamp().into());
|
||||
}
|
||||
|
||||
self.persist().await.unwrap();
|
||||
self.persist().await
|
||||
}
|
||||
|
||||
#[tracing::instrument(ret, level="debug")]
|
||||
|
Reference in New Issue
Block a user