]> source.dussan.org Git - gitea.git/commit
Store read access in access for team repo's (#20275) (#20276)
authorGusted <williamzijl7@hotmail.com>
Sat, 9 Jul 2022 18:01:44 +0000 (20:01 +0200)
committerGitHub <noreply@github.com>
Sat, 9 Jul 2022 18:01:44 +0000 (20:01 +0200)
commitd371ced49db7728b69a60b0ac2eb11467045be8c
tree877682123ab0236ffb6eaa7f5160829c69761df6
parent5e5ff77ed7731ccc608ba4851452a77eab285b9c
Store read access in access for team repo's (#20275) (#20276)

Backport #20275

Currently when a Team has read access to a organization's non-private repository, their access(in the `access` table) won't be stored in the database. This cause issues for code that rely on read access being stored, like retrieving all users who have read permission to that repository(even though this is confusing as this doesn't include all registered users). So from now-on if we see that the repository is owned by a organization don't increase the `minMode` to write permission.

Resolves #20083
models/perm/access/access.go