dkforest

A forum and chat platform (onion)
git clone https://git.dasho.dev/n0tr1v/dkforest.git
Log | Files | Refs | LICENSE

commit cefdd2788dedc398dd4cae09424cd7002e84bc10
parent 616ec24c20f5cb85c2f8a5cb2a1a9a700653d61c
Author: n0tr1v <n0tr1v@protonmail.com>
Date:   Mon, 29 May 2023 02:31:36 -0700

add doc

Diffstat:
Mpkg/web/handlers/handlers.go | 4++++
1 file changed, 4 insertions(+), 0 deletions(-)

diff --git a/pkg/web/handlers/handlers.go b/pkg/web/handlers/handlers.go @@ -5105,9 +5105,13 @@ func ChatStreamMessagesHandler(c echo.Context) error { defer sub.Close() readMarkerRev := 0 + + // If the read-marker is at the very top, it will be hidden and need to be displayed when we receive a new message. + // If it is not at the top, it will already be visible and does not need to be displayed again. fstMsgTsRound := msgs[0].CreatedAt.Round(time.Second) readMarkerTsRound := data.ReadMarker.ReadAt.Round(time.Second) displayReadMarker := fstMsgTsRound.Before(readMarkerTsRound) || fstMsgTsRound.Equal(readMarkerTsRound) + var indicatorSelector bool Loop: for {