Sha256: aa409c8d8f505180c5555e66c14245e63304a8e6b32a00c7423c1ccac3241bcc
Contents?: true
Size: 500 Bytes
Versions: 41
Compression:
Stored size: 500 Bytes
Contents
module RailsPerformance module Reports class BaseReport attr_reader :db, :group, :sort, :title def initialize(db, group: nil, sort: nil, title: nil) @db = db @group = group @sort = sort @title = title set_defaults end def collect db.group_by(group).inject([]) do |res, (k,v)| res << yield(k, v) res end end def set_defaults; end end end end
Version data entries
41 entries across 41 versions & 1 rubygems