app/models/applications/application_for_offering.rb
# If an invalid application_category is still assigned, then reset it to nil. A category is invalid if it does not match the
# ApplicationType that is currently assigned to this application.
If an invalid application_category is still assigned, then reset it to nil. A category is invalid if it does not match the
ApplicationType that is currently assigned to this application.
If an invalid application_category is still assigned then reset it to nil . A category is invalid if it does not match the ApplicationType that is currently assigned to this application .
def check_validity_of_application_category
    unless application_category.nil? || application_type.nil?
      application_category.reload && application_type.reload
      self.application_category_id = nil unless application_category.offering_application_type_id == application_type_id
    end
  end
def check_validity_of_application_category unless application_category . nil? || application_type . nil? application_category . reload && application_type . reload self . application_category_id = nil unless application_category . offering_application_type_id == application_type_id end end
If an invalid application_category is still assigned, then reset it to nil.
If an invalid application_category is still assigned then reset it to nil .