You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: pages/[subdomain]/profile/[name]/[[...tab]]/index.tsx
+1-1Lines changed: 1 addition & 1 deletion
Original file line number
Diff line number
Diff line change
@@ -1004,7 +1004,7 @@ export default function ProfilePage({
1004
1004
<pclassName='mb-4'>
1005
1005
Their user generated content is hidden and they cannot view your content.
1006
1006
<br/>
1007
-
If you believe this person is violating our terms of service, or for more help, visit our <ahref='https://discord.gg/j6RxRdqq4A'target='_blank'rel='noopener noreferrer'>Discord server</a>.
1007
+
If you believe this person is violating our terms of service, or for more help, visit our <aclassName='text-blue-500 underline'href='https://discord.gg/j6RxRdqq4A'target='_blank'rel='noopener noreferrer'>Discord server</a>.
// NB: projection is typically supposed to be the last stage of the pipeline, but we need it here because of potential sorting by calc_playattempts_unique_users_count
425
507
{$project: { ...projection}},
426
508
{
@@ -465,6 +547,8 @@ export async function doQuery(gameId: GameId, query: SearchQuery, reqUser?: User
465
547
{$skip: skip},
466
548
{$limit: limit},
467
549
...(lookupUserBeforeSort ? [] : lookupUserStage),
550
+
// If user lookup happens after pagination, apply block filter here
// NB: projection is typically supposed to be the last stage of the pipeline, but we need it here because of potential sorting by calc_playattempts_unique_users_count
587
+
// TODO: instead can have an optional $addFields here, then do the projection after
@@ -538,26 +643,14 @@ export async function doQuery(gameId: GameId, query: SearchQuery, reqUser?: User
538
643
'$facet': {
539
644
...(query.disableCount==='true' ? {} : {
540
645
metadata: [
646
+
...(reqUser ? blockFilterStageasany[] : []),// Add block filter for accurate count
541
647
{$count: 'totalRows'},
542
648
]
543
649
}),
544
-
data: [
545
-
...(lookupUserBeforeSort ? lookupUserStage : []),
546
-
// NB: projection is typically supposed to be the last stage of the pipeline, but we need it here because of potential sorting by calc_playattempts_unique_users_count
547
-
// TODO: instead can have an optional $addFields here, then do the projection after
0 commit comments