You can call this without specifying a repo at all, hence why we only care about the repository if its non-nil