From bfacf1366842055d7338df0ad5f705d5f819a60b Mon Sep 17 00:00:00 2001 From: Jeroen van Baarsen Date: Tue, 10 Dec 2013 20:33:21 +0100 Subject: Fixed all the confirm: deprecation warnings --- app/views/snippets/_blob.html.haml | 2 +- app/views/snippets/_form.html.haml | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) (limited to 'app/views/snippets') diff --git a/app/views/snippets/_blob.html.haml b/app/views/snippets/_blob.html.haml index dc856f84be9..e0152143a95 100644 --- a/app/views/snippets/_blob.html.haml +++ b/app/views/snippets/_blob.html.haml @@ -6,7 +6,7 @@ .btn-group.tree-btn-group.pull-right - if @snippet.author == current_user = link_to "Edit", edit_snippet_path(@snippet), class: "btn btn-tiny", title: 'Edit Snippet' - = link_to "Delete", snippet_path(@snippet), method: :delete, confirm: "Are you sure?", class: "btn btn-tiny", title: 'Delete Snippet' + = link_to "Delete", snippet_path(@snippet), method: :delete, data: { confirm: "Are you sure?" }, class: "btn btn-tiny", title: 'Delete Snippet' = link_to "Raw", raw_snippet_path(@snippet), class: "btn btn-tiny", target: "_blank" - unless @snippet.content.empty? - if gitlab_markdown?(@snippet.file_name) diff --git a/app/views/snippets/_form.html.haml b/app/views/snippets/_form.html.haml index 517c81fae8d..9da520e2a18 100644 --- a/app/views/snippets/_form.html.haml +++ b/app/views/snippets/_form.html.haml @@ -46,7 +46,7 @@ - unless @snippet.new_record? .pull-right.prepend-left-20 - = link_to 'Remove', snippet_path(@snippet), confirm: 'Removed snippet cannot be restored! Are you sure?', method: :delete, class: "btn btn-remove delete-snippet", id: "destroy_snippet_#{@snippet.id}" + = link_to 'Remove', snippet_path(@snippet), data: { confirm: 'Removed snippet cannot be restored! Are you sure?'}, method: :delete, class: "btn btn-remove delete-snippet", id: "destroy_snippet_#{@snippet.id}" = link_to "Cancel", snippets_path(@project), class: "btn btn-cancel" -- cgit v1.2.1