refactoring
This commit is contained in:
parent
48924dfeea
commit
c463eeb090
7 changed files with 66 additions and 37 deletions
|
@ -7,9 +7,8 @@
|
|||
= @snippet.file_name
|
||||
%br/
|
||||
.view_file_content
|
||||
- ft = handle_file_type(@snippet.file_name)
|
||||
:erb
|
||||
<%= raw Albino.colorize(@snippet.content, ft, :html, 'utf-8', "linenos=True") %>
|
||||
<%= raw @snippet.colorize %>
|
||||
|
||||
- if can?(current_user, :admin_snippet, @project) || @snippet.author == current_user
|
||||
= link_to 'Edit', edit_project_snippet_path(@project, @snippet), :class => "lbutton positive"
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue