fix: only log payload keys for edit profile payload

This commit is contained in:
Michael Zetterberg
2024-08-27 09:57:34 +02:00
parent 68aa6e565d
commit d76e8780de

View File

@@ -11,6 +11,7 @@ import { editProfileSchema } from "@/components/Forms/Edit/Profile/schema"
import { countriesMap } from "@/components/TempDesignSystem/Form/Country/countries"
import { getIntl } from "@/i18n"
import { phoneValidator } from "@/utils/phoneValidator"
import { getMembership } from "@/utils/user"
import { Status } from "@/types/components/myPages/myProfile/edit"
@@ -132,7 +133,10 @@ export const editProfile = protectedServerActionProcedure
status: Status.success,
}
} else {
console.log(`[edit profile] body: ${JSON.stringify(body)}`)
const membership = getMembership(profile.memberships)
console.log(
`[edit profile: ${membership?.membershipNumber}] body keys: ${JSON.stringify(Object.keys(body))}`
)
}
const apiResponse = await api.patch(api.endpoints.v1.profile, {