Gitlab::Git::Repository#branches_filter is calling Gitaly n+1 times per invocation
Gitlab::Git::Repository#branches_filter
is calling Gitaly n+1
times per invocation
This code needs to be refactored to fetch all required information in a single call.