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
diff options
context:
space:
mode:
authorMarin Jankovski <maxlazio@gmail.com>2015-12-07 17:03:50 +0300
committerMarin Jankovski <maxlazio@gmail.com>2015-12-07 17:03:50 +0300
commite53b350cb6db7438c1a50c500b324fd87afc41c4 (patch)
tree61626047bbb7c248e1e245dc9dde291a9ae65b5a /app/helpers/tree_helper.rb
parentb2c4675cb0e681027334e5bd046451d3116924c8 (diff)
Add specs for showing lfs object in UI.
Diffstat (limited to 'app/helpers/tree_helper.rb')
-rw-r--r--app/helpers/tree_helper.rb4
1 files changed, 4 insertions, 0 deletions
diff --git a/app/helpers/tree_helper.rb b/app/helpers/tree_helper.rb
index 03a49e119b8..6afa1aacc5b 100644
--- a/app/helpers/tree_helper.rb
+++ b/app/helpers/tree_helper.rb
@@ -54,6 +54,10 @@ module TreeHelper
::Gitlab::GitAccess.new(current_user, project).can_push_to_branch?(ref)
end
+ def can_delete_or_replace?(blob)
+ allowed_tree_edit? && !blob.lfs_pointer?
+ end
+
def tree_breadcrumbs(tree, max_links = 2)
if @path.present?
part_path = ""