removed joi validation
This commit is contained in:
1 parent
f001419a5b
commit
de3511963c
2 files changed
+7
-4
No files matched your search
@@ -153,7 +153,7 @@ const TeamPanel = () => {
|
||||
|
||||
try {
|
||||
await networkService.sendInvitationToken({
|
||||
email: toInvite.email,
|
||||
email: toInvite.email.toLowerCase(),
|
||||
role: toInvite.role,
|
||||
});
|
||||
closeInviteModal();
|
||||
|
||||
@@ -12,7 +12,8 @@ const initialState = {
|
||||
|
||||
export const register = createAsyncThunk("auth/register", async (form, thunkApi) => {
|
||||
try {
|
||||
const res = await networkService.registerUser(form);
|
||||
const newForm = {...form, email: form.email.toLowerCase()}
|
||||
const res = await networkService.registerUser(newForm);
|
||||
return res.data;
|
||||
} catch (error) {
|
||||
if (error.response.data) {
|
||||
@@ -28,7 +29,8 @@ export const register = createAsyncThunk("auth/register", async (form, thunkApi)
|
||||
|
||||
export const login = createAsyncThunk("auth/login", async (form, thunkApi) => {
|
||||
try {
|
||||
const res = await networkService.loginUser(form);
|
||||
const newForm = {...form, email: form.email.toLowerCase()}
|
||||
const res = await networkService.loginUser(newForm);
|
||||
return res.data;
|
||||
} catch (error) {
|
||||
if (error.response && error.response.data) {
|
||||
@@ -98,7 +100,8 @@ export const forgotPassword = createAsyncThunk(
|
||||
"auth/forgotPassword",
|
||||
async (form, thunkApi) => {
|
||||
try {
|
||||
const res = await networkService.forgotPassword(form);
|
||||
const newForm = {...form, email: form.toLowerCase()};
|
||||
const res = await networkService.forgotPassword(newForm);
|
||||
return res.data;
|
||||
} catch (error) {
|
||||
if (error.response.data) {
|
||||
|
||||
Reference in new issue
Block a user