From 0b8ef6309c535c04b80a5e7938defeac4a32f4ed Mon Sep 17 00:00:00 2001 From: Aida Eslami Date: Sun, 1 Mar 2026 22:05:52 +0000 Subject: [PATCH] Fix blank flash on hashtag click --- front-end/views/hashtag.mjs | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/front-end/views/hashtag.mjs b/front-end/views/hashtag.mjs index 7b7e996..5e2088a 100644 --- a/front-end/views/hashtag.mjs +++ b/front-end/views/hashtag.mjs @@ -17,8 +17,10 @@ import {createHeading} from "../components/heading.mjs"; function hashtagView(hashtag) { destroy(); - apiService.getBloomsByHashtag(hashtag); - + if (state.currentHashtag !== hashtag) { // fetches only when the hashtag changes + state.updateState({ currentHashtag: hashtag }); + apiService.getBloomsByHashtag(hashtag); + } renderOne( state.isLoggedIn, getLogoutContainer(),