Load a repository and the viewer's standing on it in one D1 statement
requireRepoAccess, the scoped API helper, raw downloads and LFS read the viewer's org membership and collaborator grant with the repository row, so repoPermission needs no further D1 reads for that viewer. Rows loaded for one viewer are re-checked for any other. Assisted-by: Crush
5 files changed+128−19
Rendering diff…