fix unnecessary copy every frame

Signed-off-by: kernelkind <kernelkind@gmail.com>
This commit is contained in:
kernelkind
2024-10-15 11:45:13 -04:00
parent e5ba897ce6
commit 0a077ae797
4 changed files with 9 additions and 6 deletions

View File

@@ -15,7 +15,7 @@ use crate::{
use super::timeline::{tabs_ui, TimelineTabView};
pub struct ProfileView<'a> {
pubkey: Pubkey,
pubkey: &'a Pubkey,
col_id: usize,
profiles: &'a mut NotesHolderStorage<Profile>,
ndb: &'a Ndb,
@@ -25,7 +25,7 @@ pub struct ProfileView<'a> {
impl<'a> ProfileView<'a> {
pub fn new(
pubkey: Pubkey,
pubkey: &'a Pubkey,
col_id: usize,
profiles: &'a mut NotesHolderStorage<Profile>,
ndb: &'a Ndb,

View File

@@ -1,6 +1,9 @@
use crate::{
actionbar::TimelineResponse, imgcache::ImageCache, notecache::NoteCache,
notes_holder::{NotesHolder, NotesHolderStorage}, thread::Thread,
actionbar::TimelineResponse,
imgcache::ImageCache,
notecache::NoteCache,
notes_holder::{NotesHolder, NotesHolderStorage},
thread::Thread,
};
use nostrdb::{Ndb, NoteKey, Transaction};
use tracing::error;