components/financial_assistance/app/models/financial_assistance/applicant.rb
def covering_applicant_exists?
      return true if claimed_as_tax_dependent_by.blank?
      tax_claimer_present = application.applicants.where(_id: claimed_as_tax_dependent_by).present?
      errors.add(:base, "Applicant claiming #{applicant.full_name} as tax dependent not present.") if tax_claimer_present.blank?
      tax_claimer_present
    end
# If there is no claimed_as_tax_dependent_by, return true
# if there is a claimed_as_tax_dependent_by, make sure that the application
# has an applicant with that id
If there is no claimed_as_tax_dependent_by, return true
if there is a claimed_as_tax_dependent_by, make sure that the application
has an applicant with that id
If there is no claimed_as_tax_dependent_by return true if there is a claimed_as_tax_dependent_by make sure that the application has an applicant with that id
def covering_applicant_exists?
      return true if claimed_as_tax_dependent_by.blank?
      tax_claimer_present = application.applicants.where(_id: claimed_as_tax_dependent_by).present?
      errors.add(:base, "Applicant claiming #{applicant.full_name} as tax dependent not present.") if tax_claimer_present.blank?
      tax_claimer_present
    end
def covering_applicant_exists? return true if claimed_as_tax_dependent_by . blank? tax_claimer_present = application . applicants . where ( _id : claimed_as_tax_dependent_by ) . present? errors . add ( :base , "Applicant claiming #{applicant.full_name} as tax dependent not present." ) if tax_claimer_present . blank? tax_claimer_present end
If there is no claimed_as_tax_dependent_by, return true
if there is a claimed_as_tax_dependent_by, make sure that the application
has an applicant with that id
If there is no claimed_as_tax_dependent_by return true if there is a claimed_as_tax_dependent_by make sure that the application has an applicant with that id