diff options
author | Sean McGivern <sean@gitlab.com> | 2016-07-18 11:58:50 +0100 |
---|---|---|
committer | Sean McGivern <sean@gitlab.com> | 2016-07-18 11:58:50 +0100 |
commit | 55e2e7a5cc078e731ff647c4f5b0d774c6646181 (patch) | |
tree | e1e95bee402eb56c22fccf3abb83e06471b69da7 | |
parent | 2556d6d34761b6cfc4a81cfcb8f9c4a2fea114dc (diff) | |
download | gitlab-ce-19928-nomethoderror-undefined-method-id-for-nil-nilclass.tar.gz |
Don't blow up in tree view on empty repo19928-nomethoderror-undefined-method-id-for-nil-nilclass
-rw-r--r-- | app/controllers/projects_controller.rb | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/app/controllers/projects_controller.rb b/app/controllers/projects_controller.rb index 1803aa8eab4..4e5bcff9cf8 100644 --- a/app/controllers/projects_controller.rb +++ b/app/controllers/projects_controller.rb @@ -5,7 +5,7 @@ class ProjectsController < Projects::ApplicationController before_action :project, except: [:new, :create] before_action :repository, except: [:new, :create] before_action :assign_ref_vars, only: [:show], if: :repo_exists? - before_action :tree, only: [:show], if: :project_view_files? + before_action :tree, only: [:show], if: [:repo_exists?, :project_view_files?] # Authorize before_action :authorize_admin_project!, only: [:edit, :update, :housekeeping, :download_export, :export, :remove_export, :generate_new_export] |