db: Short cut visibility check in HasRepository query
Created by: eseliger
As we are only interested if there is any match, we can bail out early and don't need to actually check for all the matching rows on the heap if they're visible.
Created by: eseliger
As we are only interested if there is any match, we can bail out early and don't need to actually check for all the matching rows on the heap if they're visible.