diff options
author | Phil Hughes <me@iamphill.com> | 2016-02-23 09:06:26 +0000 |
---|---|---|
committer | Phil Hughes <me@iamphill.com> | 2016-02-23 09:06:26 +0000 |
commit | d80205b75502ad53b4db085b0fd7fc2a1cb54b05 (patch) | |
tree | 62f221b3f8045bca3736352f323a7b8081d6eea5 /app/controllers | |
parent | 7c8099853621cc2a244bf6e0fd37a8b503d1ec5e (diff) | |
download | gitlab-ce-d80205b75502ad53b4db085b0fd7fc2a1cb54b05.tar.gz |
Fixes issue with file view rows not clickable on project main viewfiles-view-row-click
Fixed an issue where it would only load the first 25 commit data on project main view
Stopped the file view sending 1 too many requests
Fixes #3916
Diffstat (limited to 'app/controllers')
-rw-r--r-- | app/controllers/projects/refs_controller.rb | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/app/controllers/projects/refs_controller.rb b/app/controllers/projects/refs_controller.rb index a8f091819ca..8aeff064732 100644 --- a/app/controllers/projects/refs_controller.rb +++ b/app/controllers/projects/refs_controller.rb @@ -64,9 +64,9 @@ class Projects::RefsController < Projects::ApplicationController } end - if @logs.present? - @log_url = namespace_project_tree_url(@project.namespace, @project, tree_join(@ref, @path || '/')) - @more_log_url = logs_file_namespace_project_ref_path(@project.namespace, @project, @ref, @path || '', offset: (@offset + @limit)) + offset = (@offset + @limit) + if contents.size > offset + @more_log_url = logs_file_namespace_project_ref_path(@project.namespace, @project, @ref, @path || '', offset: offset) end respond_to do |format| |