Optimize ProjectWiki#empty? check
The empty?
check was iterating over all Wiki pages to determine
whether it was empty. Using the limit parameter allows us to bail
out early once we found a page.
Note that this currently only improves performance for GitLab 11.0 until gitaly#1204 (closed) is fixed.
Relates to #40101 (closed)