Incorrect title for guest users
-
Hi,
Since the latest update, guest users will get an incorrect tab title on the 1st load of a page.
The tab title doesn't reflect the page content. (Not terrible since it corrects itself at the 1st navigation, but still strange).
This seems to be connected to this pull request.@baris was this an intentional side effect?
-
@baris said in Incorrect title for guest users:
Can you reproduce on this forum?
Yes. (Just right click any link to a post and open in incognito)
but each page's header is cached separately
The code doesn't seem to agree with that statement...
It would seem that the cache key is based only on {template, language, method}.NodeBB/src/middleware/render.js at e81e88f3e93bc153763c11df1931c5c20de5afa6 · NodeBB/NodeBB
Node.js based forum software built for the modern web - NodeBB/src/middleware/render.js at e81e88f3e93bc153763c11df1931c5c20de5afa6 · NodeBB/NodeBB
GitHub (github.com)
-
Yeah you are right, cache is for each template so in this case topic.tpl is cached for each language but since each topic has a different title the first one that gets cached is being displayed for other topic pages. Looks like might have to remove this cache, topic title isn't the only wrong value. bodyClass and meta tags are wrong as well.