Only record a note as viewed if it isn't already recorded as such

This commit is contained in:
Mike Dilger 2023-08-09 14:22:35 +12:00
parent 7683d9d083
commit cbcf2d6e54

View File

@ -137,7 +137,8 @@ pub(super) fn render_note(
app.height.insert(id, bottom.y - top.y);
// Mark post as viewed if hovered AND we are not scrolling
if inner_response.response.hovered() && app.current_scroll_offset == 0.0 {
if !viewed && inner_response.response.hovered() && app.current_scroll_offset == 0.0
{
let _ = GLOBALS.storage.mark_event_viewed(id, None);
}