From a85ec472b9d3a2337b81e531824333734b07912a Mon Sep 17 00:00:00 2001 From: Marshall Polaris Date: Fri, 12 Aug 2022 15:27:59 -0700 Subject: [PATCH] Fix lint --- web/components/comments-list.tsx | 4 ++-- web/pages/[username]/index.tsx | 6 ++---- 2 files changed, 4 insertions(+), 6 deletions(-) diff --git a/web/components/comments-list.tsx b/web/components/comments-list.tsx index 0790b9c7..90542d4b 100644 --- a/web/components/comments-list.tsx +++ b/web/components/comments-list.tsx @@ -1,5 +1,5 @@ import { useEffect, useState } from 'react' -import { Dictionary, groupBy, keyBy, mapValues, uniq } from 'lodash' +import { Dictionary, keyBy, uniq } from 'lodash' import { Comment } from 'common/comment' import { Contract } from 'common/contract' @@ -59,7 +59,7 @@ export function UserCommentsList(props: { user: User }) { {pageComments.map(({ key, items }, i) => { const contract = contracts[key] return ( -
+
{ const creds = await authenticateOnServer(ctx) const [auth, user] = (await Promise.all([ creds != null ? getUserAndPrivateUser(creds.user.uid) : null, - getUserByUsername(ctx.params!.username as string), + getUserByUsername(ctx.params!.username as string), // eslint-disable-line @typescript-eslint/no-non-null-assertion ])) as [UserAndPrivateUser | null, User | null] - return { - props: { auth, user }, - } + return { props: { auth, user } } } export default function UserProfile(props: { user: User | null }) {