chiark
/
gitweb
/
~ian
/
mastodonochrome.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
30b6eac
)
When caching a status, cache its reblog too.
author
Simon Tatham
<anakin@pobox.com>
Wed, 3 Jan 2024 16:26:46 +0000
(16:26 +0000)
committer
Simon Tatham
<anakin@pobox.com>
Thu, 4 Jan 2024 06:58:23 +0000
(06:58 +0000)
That's another whole status, which we should be able to look up.
src/client.rs
patch
|
blob
|
history
diff --git
a/src/client.rs
b/src/client.rs
index b9e05895572091990edc08ec43d209a33cd73c0d..fd1f667d7adca32538576f3c30ca1898f2a0e81b 100644
(file)
--- a/
src/client.rs
+++ b/
src/client.rs
@@
-318,6
+318,9
@@
impl Client {
fn cache_status(&mut self, st: &Status) {
self.cache_account(&st.account);
self.statuses.insert(st.id.to_string(), st.clone());
+ if let Some(ref sub) = st.reblog {
+ self.statuses.insert(sub.id.to_string(), *sub.clone());
+ }
}
fn cache_notification(&mut self, n: &Notification) {