function Promise.defer(W)local T=debug.traceback(nil,2)local X X=Promise._new(T,function(X,Q,t)local G G=Promise._timeEvent:Connect(function()G:Disconnect()local J,d,E=runExecutor(T,W,X,Q,t)if not J then Q(E[1])end end)end)return X end

function Promise.defer(callback)
	local traceback = debug.traceback(nil, 2)
	local promise
	promise = Promise._new(traceback, function(resolve, reject, onCancel)
		local connection
		connection = Promise._timeEvent:Connect(function()
			connection:Disconnect()
			local ok, _, result = runExecutor(traceback, callback, resolve, reject, onCancel)

			if not ok then
				reject(result[1])
			end
		end)
	end)

	return promise
end
