mirror of
https://github.com/langgenius/dify.git
synced 2026-01-06 06:26:00 +00:00
correct api of email sending
This commit is contained in:
@@ -52,10 +52,9 @@ const TransferOwnershipModal = ({ onClose, show }: Props) => {
|
||||
|
||||
const sendEmail = async () => {
|
||||
try {
|
||||
const res = await sendOwnerEmail(
|
||||
userProfile.id,
|
||||
{},
|
||||
)
|
||||
const res = await sendOwnerEmail({
|
||||
language: userProfile.interface_language,
|
||||
})
|
||||
startCount()
|
||||
if (res.data)
|
||||
setStepToken(res.data)
|
||||
|
||||
@@ -131,8 +131,8 @@ export const deleteMemberOrCancelInvitation: Fetcher<CommonResponse, { url: stri
|
||||
return del<CommonResponse>(url)
|
||||
}
|
||||
|
||||
export const sendOwnerEmail = (memberID: string, body: { language?: string }) =>
|
||||
post<CommonResponse & { data: string }>(`/workspaces/current/members/${memberID}/send-owner-transfer-confirm-email`, { body })
|
||||
export const sendOwnerEmail = (body: { language?: string }) =>
|
||||
post<CommonResponse & { data: string }>('/workspaces/current/members/send-owner-transfer-confirm-email', { body })
|
||||
|
||||
export const verifyOwnerEmail = (body: { code: string; token: string }) =>
|
||||
post<CommonResponse & { is_valid: boolean; email: string; token: string }>('/workspaces/current/members/owner-transfer-check', { body })
|
||||
|
||||
Reference in New Issue
Block a user