Welcome to mirror list, hosted at ThFree Co, Russian Federation.

gitlab.com/gitlab-org/gitlab-foss.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
path: root/app
diff options
context:
space:
mode:
authorJeroen van Baarsen <jeroenvanbaarsen@gmail.com>2013-12-10 01:36:45 +0400
committerDmitriy Zaporozhets <dmitriy.zaporozhets@gmail.com>2013-12-10 14:11:28 +0400
commit2293cb1051de5d4a0d5842ce82329bd0656673e0 (patch)
treebca4beee8e27656fd93f157d279c5d0e25aa51f7 /app
parent92ce4904b9b531eeda408bdd0bd12ba2be0739f4 (diff)
Fixed some deprecations
* Model.all is deprecacted, use without .all * confirm: message is deprecated, needed to be wrapped in data block
Diffstat (limited to 'app')
-rw-r--r--app/contexts/issues/bulk_update_context.rb2
-rw-r--r--app/views/projects/branches/_branch.html.haml2
-rw-r--r--app/views/projects/tags/index.html.haml2
3 files changed, 3 insertions, 3 deletions
diff --git a/app/contexts/issues/bulk_update_context.rb b/app/contexts/issues/bulk_update_context.rb
index 73a3c353523..ab38a4f8ab5 100644
--- a/app/contexts/issues/bulk_update_context.rb
+++ b/app/contexts/issues/bulk_update_context.rb
@@ -22,7 +22,7 @@ module Issues
opts[:milestone_id] = milestone_id if milestone_id.present?
opts[:assignee_id] = assignee_id if assignee_id.present?
- issues = Issue.where(id: issues_ids).all
+ issues = Issue.where(id: issues_ids)
issues = issues.select { |issue| can?(current_user, :modify_issue, issue) }
issues.each do |issue|
diff --git a/app/views/projects/branches/_branch.html.haml b/app/views/projects/branches/_branch.html.haml
index 4372647a41c..49c97a86e2a 100644
--- a/app/views/projects/branches/_branch.html.haml
+++ b/app/views/projects/branches/_branch.html.haml
@@ -18,7 +18,7 @@
Compare
- if can?(current_user, :admin_project, @project) && branch.name != @repository.root_ref
- = link_to project_branch_path(@project, branch.name), class: 'btn grouped btn-small remove-row', method: :delete, confirm: 'Removed branch cannot be restored. Are you sure?', remote: true do
+ = link_to project_branch_path(@project, branch.name), class: 'btn grouped btn-small remove-row', method: :delete, data: { confirm: 'Removed branch cannot be restored. Are you sure?'}, remote: true do
%i.icon-trash
%p
diff --git a/app/views/projects/tags/index.html.haml b/app/views/projects/tags/index.html.haml
index 5361517b2fc..8b609680219 100644
--- a/app/views/projects/tags/index.html.haml
+++ b/app/views/projects/tags/index.html.haml
@@ -37,7 +37,7 @@
%i.icon-download-alt
Download
- if can?(current_user, :admin_project, @project)
- = link_to project_tag_path(@project, tag.name), class: 'btn btn-small remove-row', method: :delete, confirm: 'Removed tag cannot be restored. Are you sure?', remote: true do
+ = link_to project_tag_path(@project, tag.name), class: 'btn btn-small remove-row', method: :delete, data: { confirm: 'Removed tag cannot be restored. Are you sure?'}, remote: true do
%i.icon-trash
= paginate @tags, theme: 'gitlab'