var data = {
"username": login,
"password": password,
"passwordAgain": password
};
if (password.length <= 5 || login.length <= 3)
throw new Error("Password / Username to short !");
console.log(`${SERVER_URL}/register`);
const response = await fetch(`${SERVER_URL}/register`,{
method:'POST',
headers:{ 'content-type': 'application/json' },
body: data // < ===== Error from here ! Change it to JSON.stringify(data)
});
const body = await response.text();
const $ = cheerio.load(body);