notedeck

One damus client to rule them all
git clone git://jb55.com/notedeck
Log | Files | Refs | README | LICENSE

commit 2603d08d1a41bd6b10646db3f35e4fc969aee967
parent ad9c8f959cfba10713b1b7b90d2dad051578e825
Author: William Casarin <jb55@jb55.com>
Date:   Mon,  2 Sep 2024 18:31:53 -0700

tidy: fix formatting

Signed-off-by: William Casarin <jb55@jb55.com>

Diffstat:
Msrc/column.rs | 2+-
Msrc/timeline.rs | 11+++++------
Msrc/ui/thread.rs | 3++-
3 files changed, 8 insertions(+), 8 deletions(-)

diff --git a/src/column.rs b/src/column.rs @@ -1,6 +1,6 @@ use crate::error::FilterError; -use crate::filter::FilterState; use crate::filter; +use crate::filter::FilterState; use crate::{timeline::Timeline, Error}; use enostr::Pubkey; use nostrdb::{Filter, Ndb, Transaction}; diff --git a/src/timeline.rs b/src/timeline.rs @@ -70,12 +70,11 @@ impl<'a> TimelineSource<'a> { /// Check local subscriptions for new notes and insert them into /// timelines (threads, columns) pub fn poll_notes_into_view(&self, txn: &Transaction, app: &mut Damus) -> Result<()> { - let sub = - if let Some(sub) = self.sub(app, txn) { - sub - } else { - return Err(Error::no_active_sub()); - }; + let sub = if let Some(sub) = self.sub(app, txn) { + sub + } else { + return Err(Error::no_active_sub()); + }; let new_note_ids = app.ndb.poll_for_notes(sub, 100); if new_note_ids.is_empty() { diff --git a/src/ui/thread.rs b/src/ui/thread.rs @@ -71,7 +71,8 @@ impl<'a> ThreadView<'a> { }; // poll for new notes and insert them into our existing notes - if let Err(e) = TimelineSource::Thread(root_id).poll_notes_into_view(&txn, self.app) { + if let Err(e) = TimelineSource::Thread(root_id).poll_notes_into_view(&txn, self.app) + { error!("Thread::poll_notes_into_view: {e}"); }