Commit 622b951d authored by Sean McGivern's avatar Sean McGivern

Merge CE master

parents 0af52eb6 24985807
...@@ -24,10 +24,10 @@ module SearchHelper ...@@ -24,10 +24,10 @@ module SearchHelper
end end
def search_entries_info(collection, scope, term) def search_entries_info(collection, scope, term)
return unless collection.count > 0 return if collection.to_a.empty?
from = collection.offset_value + 1 from = collection.offset_value + 1
to = collection.offset_value + collection.count to = collection.offset_value + collection.to_a.size
count = collection.total_count count = collection.total_count
"Showing #{from} - #{to} of #{count} #{scope.humanize(capitalize: false)} for \"#{term}\"" "Showing #{from} - #{to} of #{count} #{scope.humanize(capitalize: false)} for \"#{term}\""
......
- if @search_objects.empty? - if @search_objects.to_a.empty?
= render partial: "search/results/empty" = render partial: "search/results/empty"
= render 'shared/promotions/promote_advanced_search' = render 'shared/promotions/promote_advanced_search'
- else - else
......
---
title: Improve snippet search performance by removing duplicate counts
merge_request: 23952
author:
type: performance
...@@ -12,7 +12,7 @@ Since installations from source don't have Runit, Sidekiq can't be terminated an ...@@ -12,7 +12,7 @@ Since installations from source don't have Runit, Sidekiq can't be terminated an
## Select Version to Install ## Select Version to Install
Make sure you view [this installation guide](https://gitlab.com/gitlab-org/gitlab-ce/blob/master/doc/install/installation.md) from the branch (version) of GitLab you would like to install (e.g., `11-6-stable`). Make sure you view [this installation guide](https://gitlab.com/gitlab-org/gitlab-ce/blob/master/doc/install/installation.md) from the branch (version) of GitLab you would like to install (e.g., `11-7-stable`).
You can select the branch in the version dropdown in the top left corner of GitLab (below the menu bar). You can select the branch in the version dropdown in the top left corner of GitLab (below the menu bar).
If the highest number stable branch is unclear please check the [GitLab Blog](https://about.gitlab.com/blog/) for installation guide links by version. If the highest number stable branch is unclear please check the [GitLab Blog](https://about.gitlab.com/blog/) for installation guide links by version.
...@@ -300,9 +300,9 @@ sudo usermod -aG redis git ...@@ -300,9 +300,9 @@ sudo usermod -aG redis git
### Clone the Source ### Clone the Source
# Clone GitLab repository # Clone GitLab repository
sudo -u git -H git clone https://gitlab.com/gitlab-org/gitlab-ce.git -b 11-6-stable gitlab sudo -u git -H git clone https://gitlab.com/gitlab-org/gitlab-ce.git -b 11-7-stable gitlab
**Note:** You can change `11-6-stable` to `master` if you want the *bleeding edge* version, but never install master on a production server! **Note:** You can change `11-7-stable` to `master` if you want the *bleeding edge* version, but never install master on a production server!
### Configure It ### Configure It
......
This diff is collapsed.
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment