So basically this script is supposed to make it so when a player has donated 5+ robux it sends a message on Discord telling the moderators to give them the Donator role. When I test the game it gives this error 'ServerScriptService.Discord Webhook:15: ')' expected (to close '(' at line 4) near 'end''. How would I fix this?
local url = 'https://discord.osyr.is/api/webhooks/removedcodeforsecurity'
local http = game:GetService("HttpService")
game.Players.PlayerAdded:Connect(function(player)
wait(1)
repeat wait() until player.leaderstats.Donated.Value == 0
repeat wait() until player.leaderstats.Donated.Value >= 5
local data = {
['username'] = "???? NEW DONATION ????",
['content'] = "Looks like, **".. player.Name.. "** has donated over 5 Robux! Looks like they deserve the donator role <@roleidremovedforsecurity>!"
}
local newdata = http:JSONEncode(data)
http:PostAsync(url,newdata)
end
end)

1 comment
These errors are self explanatory