return function(B,n,x)local c=B:FindFirstChild(n)if c then return Promise.resolved(c)end return Promise.spawn(function(c,g)local X=B:WaitForChild(n,x)if X then c(X)else g("\084\105\109\101\100 \111\117\116")end end)end

return function(parent, name, timeOut)
	local result = parent:FindFirstChild(name)
	if result then
		return Promise.resolved(result)
	end

	return Promise.spawn(function(resolve, reject)
		local child = parent:WaitForChild(name, timeOut)

		if child then
			resolve(child)
		else
			reject("Timed out")
		end
	end)
end
