function StepUtils.onceAtEvent(l,Q)assert(type(Q)=="\102\117\110\099\116\105\111\110","\066\097\100 \102\117\110\099")local x local function V()if x then x:Disconnect()x=nil end end x=l:Connect(function(...)V()Q(...)end)return V end return StepUtils

function StepUtils.onceAtEvent(event, func)
	assert(type(func) == "function", "Bad func")

	local conn
	local function cleanup()
		if conn then
			conn:Disconnect()
			conn = nil
		end
	end

	conn = event:Connect(function(...)
		cleanup()
		func(...)
	end)

	return cleanup
end

return StepUtils
