Sha256: 7486a85e6b2141b9635cca51c5b872cba485febbc09522875b1c2944e64d5b90
Contents?: true
Size: 473 Bytes
Versions: 12
Compression:
Stored size: 473 Bytes
Contents
# frozen_string_literal: true module Mihari module Schemas module Concerns # # OR-rable concern # module Orrable extend ActiveSupport::Concern def get_or_composition schemas = constants.map { |sym| const_get sym } return schemas.first if schemas.length <= 1 base, *others = schemas others.each { |other| base = base.or(other) } base end end end end end
Version data entries
12 entries across 12 versions & 1 rubygems