class Rails::Railtie
def register_block_for(type, &blk)
blank and append given block to value, which will be used later in
receives an instance variable identifier, set the variable value if is
def register_block_for(type, &blk) var_name = "@#{type}" blocks = instance_variable_defined?(var_name) ? instance_variable_get(var_name) : instance_variable_set(var_name, []) blocks << blk if blk blocks end