fix: minor type fixes

This commit is contained in:
melvinchia3636
2026-06-24 01:35:28 +08:00
parent 781b1356af
commit aed7b924f1
2 changed files with 4 additions and 7 deletions

View File

@@ -40,13 +40,13 @@ function ModifyModal<TType extends 'datetime' | 'text'>({
const mutation = useMutation(
forgeAPI.user.settings.updateProfile.mutationOptions({
onSuccess: (_: never, newData: UserData) => {
onSuccess: (_, newData) => {
if (!userData) return
if (id === 'email') {
toast.info('A verification email has been sent to your new email.')
} else {
setUserData((oldData: UserData) => {
setUserData(oldData => {
if (!oldData) return null
return { ...oldData, ...newData.data } as UserData