Sha256: 8480a5fb602f5752eeaa3751dde32036faacf309fe24350a14eddfac40a31579
Contents?: true
Size: 586 Bytes
Versions: 5
Compression:
Stored size: 586 Bytes
Contents
module Rtml::Controller::TemplateHelpers def default_template_exists? template_exists?(default_template_name) end unless ActionController::Base.private_instance_methods.include? 'template_exists?' def template_exists?(template_name, fmt = response.template.template_format) self.view_paths.find_template(template_name, fmt) rescue ActionView::MissingTemplate, Errno::ENOENT false end end class << self def included(base) base.instance_eval do hide_action :default_template_exists?, :template_exists? end end end end
Version data entries
5 entries across 5 versions & 1 rubygems