Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Bug report: Don't support async await #438

Closed
mernsolution opened this issue May 18, 2023 · 1 comment · Fixed by #439
Closed

Bug report: Don't support async await #438

mernsolution opened this issue May 18, 2023 · 1 comment · Fixed by #439

Comments

@mernsolution
Copy link

Describe the bug
export async function RegistrationApi(userName,userMail,
userPassword, userPhoto) {
try {
Store.dispatch(showLoader());
const URL = ${Base_url}/register;
const postBody = {
userMail,
userName,
userPassword,
userPhoto
};
const res = await axios.post(URL, postBody);
if (res.status === 200) {
return true;
} else {
toast.error("Failed to register");
return false;
}
} catch (error) {
Store.dispatch(HideLoader());
console.log(error);
return false;
}
}
Problem JsLint can not read async and await my code is okay but jsLint say warning

@mernsolution mernsolution changed the title Bug report: Your title here Bug report: Can not support async await May 18, 2023
@mernsolution mernsolution changed the title Bug report: Can not support async await Bug report: Don't support async await May 18, 2023
@kaizhu256
Copy link
Member

thx for reporting. jslint now has proper grammar for recognizing export async function ...

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants