Sha256: 544feecae1690cbfea4f105015215fd0bb59adf5cb2d30136fe19eb45996d05e
Contents?: true
Size: 383 Bytes
Versions: 7
Compression:
Stored size: 383 Bytes
Contents
module InferredCrumpets class SubjectFinder def self.for_context(context) new(context).call end def initialize(context) @context = context end def call current_object = begin @context.current_object rescue nil end collection_object = begin @context.collection rescue nil end current_object || collection_object end end end
Version data entries
7 entries across 7 versions & 1 rubygems