chiark / gitweb /
Call ensure_enough_rendered even if feed update failed.
authorSimon Tatham <anakin@pobox.com>
Sun, 31 Dec 2023 13:36:15 +0000 (13:36 +0000)
committerSimon Tatham <anakin@pobox.com>
Sun, 31 Dec 2023 13:36:15 +0000 (13:36 +0000)
Because then we're tinkering with the ExtendableIndicator, so we still
need to re-check our drawability.

src/file.rs

index 0e4460506c3e6a51bccc1392343dc7dee213cc7e..f72d932cd3b5883d5395985a129296cc66f7d432 100644 (file)
@@ -427,8 +427,8 @@ impl<Type: FeedType> ActivityState for FeedFile<Type> {
             },
             Pr('0') | Home => {
                 if self.at_top() && self.contents.extender.is_some() {
-                    match client.fetch_feed(&self.contents.id,
-                                            FeedExtend::Past) {
+                    let action = match client.fetch_feed(&self.contents.id,
+                                                         FeedExtend::Past) {
                         Ok(any_new) => {
                             self.rendered.remove(&self.contents.first_index());
                             if let Some(i) = self.contents.extender_index() {
@@ -442,11 +442,11 @@ impl<Type: FeedType> ActivityState for FeedFile<Type> {
                             }
 
                             self.contents.update_items(client);
-                            self.ensure_enough_rendered();
                             LogicalAction::Nothing
                         },
                         Err(e) => LogicalAction::Error(e),
-                    }
+                    };
+                    action
                 } else {
                     self.goto_top();
                     LogicalAction::Nothing