diff --git a/frontend/src/ts/elements/profile.ts b/frontend/src/ts/elements/profile.ts index 7cb650581..2abdf826d 100644 --- a/frontend/src/ts/elements/profile.ts +++ b/frontend/src/ts/elements/profile.ts @@ -14,6 +14,7 @@ import Format from "../utils/format"; import { UserProfile, RankAndCount } from "@monkeytype/contracts/schemas/users"; import { abbreviateNumber, convertRemToPixels } from "../utils/numbers"; import { secondsToString } from "../utils/date-and-time"; +import { Auth } from "../firebase"; type ProfileViewPaths = "profile" | "account"; type UserProfileOrSnapshot = UserProfile | DB.Snapshot; @@ -331,6 +332,12 @@ export async function update( } } + if (profile.uid === Auth?.currentUser?.uid) { + profileElement.find(".userReportButton").addClass("hidden"); + } else { + profileElement.find(".userReportButton").removeClass("hidden"); + } + //structure const bioAndKey = bio || keyboard;