Script error how can I solve Argument 2 missing or nil

Hello, who can help me with this script please. There is an error on line 23 I have tried everything but I can’t solve it, if anyone know how to solve it please tell me. Thanks.

local donateAmounts = {5, 12, 25, 50}
local ids = {3260650430, 3590650616, 3570650734, 3510650846}


local mps = game:GetService("MarketplaceService")

local dss = game:GetService("DataStoreService")
local ods = dss:GetOrderedDataStore("Donators")



for i, amount in pairs(donateAmounts) do

	local donateButton = script:WaitForChild("DonateButton"):Clone()
	donateButton.Text = "<b><stroke color='#000000' joins='miter' thickness='1.5' transparency='0'> R$ "..amount.."</stroke></b>"
	donateButton.Parent = script.Parent.DonatePart.DonateGui.DonateList
end


game.ReplicatedStorage.DonateRE.OnServerEvent:Connect(function(plr, button)


	local amount = string.gsub(button.Text, "<b><stroke color='#000000' joins='miter' thickness='1.5' transparency='0'> R$ ", "") --line 23
	local id = ids[table.find(donateAmounts, tonumber(amount))]

	mps:PromptProductPurchase(plr, id)
end)


mps.ProcessReceipt = function(purchaseInfo)

	local amount = mps:GetProductInfo(purchaseInfo.ProductId, Enum.InfoType.Product).PriceInRobux

	local success, err = pcall(function()
		local totalDonated = ods:GetAsync(purchaseInfo.PlayerId) or 0
		ods:SetAsync(purchaseInfo.PlayerId, totalDonated + amount)
	end)

	return success and Enum.ProductPurchaseDecision.PurchaseGranted or Enum.ProductPurchaseDecision.NotProcessedYet
end


while wait(5) do

	for i, child in pairs(script.Parent.LeaderboardPart.LeaderboardGui.LeaderboardList:GetChildren()) do

		if child:IsA("Frame") then child:Destroy() end
	end


	local pages = ods:GetSortedAsync(false, 10)
	local top = pages:GetCurrentPage()


	for rank, data in ipairs(top) do

		local username = game.Players:GetNameFromUserIdAsync(data.key)
		local donated = data.value

		local leaderboardFrame = script.LeaderboardFrame:Clone()
		leaderboardFrame.Frame.Username.Text = rank..": "..username
		leaderboardFrame.Frame.Amount.Text = "R$ "..donated

		leaderboardFrame.Parent = script.Parent.LeaderboardPart.LeaderboardGui.LeaderboardList
	end
end

image

maybe you forgot to put a variable because its missing or nil, like this:

local function test(aaa, Color)
	aaa.Color = Color
end
test()

this script is very useless, and gives the same error you have

Are trying to change this string to “”?

game.ReplicatedStorage.DonateRE.OnServerEvent:Connect(function(plr, button)
	mps:PromptProductPurchase(plr, id)
end)

what does the other script looks like