Sha256: caef7ca8d87813f296710442b3906a71a3664401b19e2ecc68f0756972fe7c52
Contents?: true
Size: 402 Bytes
Versions: 2
Compression:
Stored size: 402 Bytes
Contents
require 'object_attorney/accusation' module ObjectAttorney class Allegation def initialize(validation) # expected to be an ActiveModel::Validations::<Class> instance @validation = validation end def founded_accusation(attorney, defendant) accusation = Accusation.new(@validation, attorney, defendant) accusation.founded ? accusation : nil end end end
Version data entries
2 entries across 2 versions & 1 rubygems
Version | Path |
---|---|
object_attorney-3.0.2 | lib/object_attorney/allegation.rb |
object_attorney-3.0.0 | lib/object_attorney/allegation.rb |