Explorar el Código

Merge pull request #6672 from weseek/fix/103550-footprints-are-not-displayed

fix: Footprints are not displayed
Shun Miyazawa hace 3 años
padre
commit
5c0dd06d7b
Se han modificado 1 ficheros con 5 adiciones y 0 borrados
  1. 5 0
      packages/app/src/pages/[[...path]].page.tsx

+ 5 - 0
packages/app/src/pages/[[...path]].page.tsx

@@ -399,6 +399,11 @@ async function injectPageData(context: GetServerSidePropsContext, props: Props):
   const pageWithMeta: IPageToShowRevisionWithMeta = await pageService.findPageAndMetaDataByViewer(pageId, currentPathname, user, true); // includeEmpty = true, isSharedPage = false
   const page = pageWithMeta?.data as unknown as PageDocument;
 
+  // add user to seen users
+  if (page != null && user != null) {
+    await page.seen(user);
+  }
+
   // populate & check if the revision is latest
   if (page != null) {
     page.initLatestRevisionField(revisionId);