summaryrefslogtreecommitdiff
path: root/app/views/layouts/snippets.html.haml
diff options
context:
space:
mode:
authorJarka Kadlecova <jarka@gitlab.com>2017-05-03 17:26:49 +0200
committerJarka Kadlecova <jarka@gitlab.com>2017-05-31 07:17:03 +0200
commit4464c22d6d23d893494682d309aec3fb31c11ae3 (patch)
treecb7490034185f79c88db472650b87afdcdbafa3f /app/views/layouts/snippets.html.haml
parent8039b9c3c6caedc19e0e44d086a007e8975134b7 (diff)
downloadgitlab-ce-4464c22d6d23d893494682d309aec3fb31c11ae3.tar.gz
Support descriptions for snippets
Diffstat (limited to 'app/views/layouts/snippets.html.haml')
-rw-r--r--app/views/layouts/snippets.html.haml5
1 files changed, 2 insertions, 3 deletions
diff --git a/app/views/layouts/snippets.html.haml b/app/views/layouts/snippets.html.haml
index 98b75cea03f..57971205e0e 100644
--- a/app/views/layouts/snippets.html.haml
+++ b/app/views/layouts/snippets.html.haml
@@ -1,9 +1,8 @@
- header_title "Snippets", snippets_path
- content_for :page_specific_javascripts do
- - if @snippet&.persisted? && current_user
+ - if @snippet && current_user
:javascript
- window.uploads_path = "#{upload_path('personal_snippet', @snippet)}";
- window.preview_markdown_path = "#{preview_markdown_snippet_path(@snippet)}";
+ window.uploads_path = "#{upload_path('personal_snippet', id: @snippet.id)}";
= render template: "layouts/application"