lib/travis/client/session.rb in travis-1.6.3.travis.390.4 vs lib/travis/client/session.rb in travis-1.6.3.travis.392.4
- old
+ new
@@ -141,9 +141,18 @@
end
end
result
end
+ def preload(list)
+ list.group_by(&:class).each do |type, instances|
+ next unless type.preloadable?
+ ids = instances.map { |e| e.id unless e.complete? }.compact
+ find_many(type, :ids => ids) if ids.any?
+ end
+ list
+ end
+
def get(*args)
load get_raw(*args)
end
def delete(*args)