make #custom_language private

This commit is contained in:
http://jneen.net/ 2016-06-21 09:23:42 -07:00
parent c8b52761bc
commit e08ff468e8

View file

@ -27,14 +27,6 @@ module Gitlab
end
end
def custom_language
return nil if @repository.nil?
language_name = @repository.gitattribute(@blob_name, 'gitlab-language')
Rouge::Lexer.find(language_name)
end
def highlight(text, continue: true, plain: false)
if plain
@formatter.format(Rouge::Lexers::PlainText.lex(text)).html_safe
@ -47,6 +39,14 @@ module Gitlab
private
def custom_language
return nil if @repository.nil?
language_name = @repository.gitattribute(@blob_name, 'gitlab-language')
Rouge::Lexer.find(language_name)
end
def rouge_formatter(options = {})
options = options.reverse_merge(
nowrap: true,