Restrict usage of project creator method for group::source code
<!--IssueSummary start--> <details> <summary> Everyone can contribute. [Help move this issue forward](https://handbook.gitlab.com/handbook/marketing/developer-relations/contributor-success/community-contributors-workflows/#contributor-links) while earning points, leveling up and collecting rewards. </summary> - [Work on this issue](https://contributors.gitlab.com/manage-issue?action=work&projectId=278964&issueIid=378994) - [Close this issue](https://contributors.gitlab.com/manage-issue?action=close&projectId=278964&issueIid=378994) </details> <!--IssueSummary end--> Like in #350603, we have some usages of `project.creator` that mean something like "just get the creator, is probably the owner". Due to the semantic difference between them, it's a good thing to restrict the `creator` method to cases when the creator of the project is strictly needed. > I see 309 occurrences of `.creator` according to a grep. Upon a quick skim most seem to be `project.creator` and some of them will not need changing. See https://gitlab.com/groups/gitlab-org/-/epics/7405#note_818917873 for more context. The vast majority of instances of `creator` are in specs/factories/fixtures excepting the below :point_down: ### Instances of `.creator` in code (not specs) | Code location | Action | MR | Team | | ------------- | ------ | ------- | ----- | | [app/services/projects/protect_default_branch_service.rb#L38](https://gitlab.com/gitlab-org/gitlab/-/blob/c7c5c09615252576e80f5b6cd35fcc61921ae58b/app/services/projects/protect_default_branch_service.rb#L38) | Ensuring a protected branch can be made. | - | ~"group::source code" | | [ee/app/workers/repository_update_mirror_worker.rb#L24](https://gitlab.com/gitlab-org/gitlab/-/blob/c7c5c09615252576e80f5b6cd35fcc61921ae58b/ee/app/workers/repository_update_mirror_worker.rb#L24) | Updating a repo via mirror.| - | ~"group::source code" | | [app/workers/repository_update_remote_mirror_worker.rb#L45](https://gitlab.com/gitlab-org/gitlab/-/blob/c7c5c09615252576e80f5b6cd35fcc61921ae58b/app/workers/repository_update_remote_mirror_worker.rb#L45) | Updating a remote repo via mirror. | - | ~"group::source code" | ## Availability and Testing - Run `e2e:package-and-test` job within the MRs for the code changes listed above. If the change is small enough / has low risk, this job may be skipped. Please review with a domain expert and ~"group::source code" SET before deciding to skip `e2e:package-and-test`
issue