Katello 4.9 is very slow

I can confirm that after commenting line 938 on repository.rb ( /usr/share/gems/gems/katello-4.9.0/app/models/katello/repository.rb ) and then run foreman-installer synchronizing repos and publishing Content Views works again.
Acessing https://foreman.mydomain.com/content_views is still slow, so this is probably not the only issue on katello 4.9.

@sajha is it safe to remove that line? Or am I causing another issues somewhere else?