Skip to content
Snippets Groups Projects
Commit 88b5abc6 authored by Angelina Filippova's avatar Angelina Filippova
Browse files

Fix parsing emails with symbols

parent ce3d3387
Branches
Tags
2 merge requests!125WIP: Release/2.0.3,!105Fix parsing emails with symbols
Pipeline #23791 passed
......@@ -13,14 +13,13 @@ export async function generateInviteToken(max_use, expires_at, authHost, token)
}
export async function inviteViaEmail(email, name, authHost, token) {
const url = name.length > 0
? `/api/pleroma/admin/users/email_invite?email=${email}&name=${name}`
: `/api/pleroma/admin/users/email_invite?email=${email}`
const data = name.length > 0 ? { email, name } : { email }
return await request({
baseURL: baseName(authHost),
url,
url: '/api/pleroma/admin/users/email_invite',
method: 'post',
headers: authHeaders(token)
headers: authHeaders(token),
data
})
}
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment