----- Private Functions -----




local function ProcessReceipt(receipt_info)
	local ProductId = receipt_info.ProductId

	local player = Players:GetPlayerByUserId(receipt_info.PlayerId)

	if player == nil then
		return Enum.ProductPurchaseDecision.NotProcessedYet
	end

	local profile = PlayerData.Profiles[player]
	if not profile then return end

	local ProductToBuy, amount = EggConfig.GetEggFromProduct(ProductId)
	
	local pets = HatchBind:Invoke(player, ProductToBuy, amount)
	
	task.wait(1.5)
	
	Remotes.Eggs.EggProductPurchased:FireClient(player, ProductToBuy, pets)
	
end
