Class: ActionView::OptimizedFileSystemResolver

Inherits:
Object
  • Object
show all
Defined in:
lib/maildown/ext/action_view.rb

Instance Method Summary collapse

Instance Method Details

#extract_handler_and_format_and_variant(*args) ⇒ Object

Different versions of rails have different method signatures here, path is always first



11
12
13
14
15
16
17
18
# File 'lib/maildown/ext/action_view.rb', line 11

def extract_handler_and_format_and_variant(*args)
  if args.first.end_with?('md.erb')
    path = args.shift
    path = path.gsub(/\.md\.erb\z/, '.md+erb')
    args.unshift(path)
  end
  return original_extract_handler_and_format_and_variant(*args)
end

#original_extract_handler_and_format_and_variantObject



7
# File 'lib/maildown/ext/action_view.rb', line 7

alias :original_extract_handler_and_format_and_variant :extract_handler_and_format_and_variant