app/helpers/washout_builder_shared_helper.rb
# Tries to constantize a string or a class to return the class
#
# @param [String] complex_class A string that contains the name of a class
# @return [Class, nil] returns the class if it is classes_defined otherwise nil
# @api public
Tries to constantize a string or a class to return the class
Tries to constantize a string or a class to return the class
def find_class_from_string(complex_class)
    complex_class.is_a?(Class) ? complex_class : complex_class.constantize
  rescue
    nil
  end
def find_class_from_string ( complex_class ) complex_class . is_a? ( Class ) ? complex_class : complex_class . constantize rescue nil end
Tries to constantize a string or a class to return the class
Tries to constantize a string or a class to return the class
returns the class if it is classes_defined otherwise nil
returns the class if it is classes_defined otherwise nil
Class, nil
complex_class
<not_specific>
<not_specific>
complex_class A string that contains the name of a class
complex_class A string that contains the name of a class
api
None