Prevent unecessary calls (#4561)

(cherry picked from commit ecb48797675c5be24508bf47141e930c64dac14e)
zio/stable
Eric Bailey 2024-06-18 13:52:44 -05:00 committed by GitHub
parent 983d85384b
commit 4165a02b2d
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194
1 changed files with 1 additions and 1 deletions

View File

@ -30,7 +30,7 @@ export function NewskieDialog({
const moderation = moderateProfile(profile, moderationOpts)
return sanitizeDisplayName(name, moderation.ui('displayName'))
}, [moderationOpts, profile])
const [now] = React.useState(Date.now())
const [now] = React.useState(() => Date.now())
const timeAgo = useGetTimeAgo()
const createdAt = profile.createdAt as string | undefined
const daysOld = React.useMemo(() => {