class SimpleForm::FormBuilder
def find_mapping(input_type)
2) If not, fallbacks to #{input_type}Input
b) Or use the found mapping
a) Try to find an alternative with the same name in the Object scope
1) It tries to find a registered mapping, if succeeds:
Attempts to find a mapping. It follows the following rules:
def find_mapping(input_type) discovery_cache[input_type] ||= if mapping = self.class.mappings[input_type] mapping_override(mapping) || mapping else camelized = "#{input_type.to_s.camelize}Input" attempt_mapping_with_custom_namespace(camelized) || attempt_mapping(camelized, Object) || attempt_mapping(camelized, self.class) || raise("No input found for #{input_type}") end end