diff options
author | Patrick Derichs <pderichs@gitlab.com> | 2019-08-28 13:03:24 +0200 |
---|---|---|
committer | Patrick Derichs <pderichs@gitlab.com> | 2019-08-28 13:03:24 +0200 |
commit | e15a6bc1cc3eb9b3670d2b42813c634117e7b04d (patch) | |
tree | 6e1299bc664e92617d11ab67af966f1ab228e504 /app | |
parent | 7321d0ab5ef6c8eef814e57c623f46120ca6d17e (diff) | |
download | gitlab-ce-e15a6bc1cc3eb9b3670d2b42813c634117e7b04d.tar.gz |
Return NO_ACCESS if user is nil
Diffstat (limited to 'app')
-rw-r--r-- | app/models/group.rb | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/app/models/group.rb b/app/models/group.rb index dbec211935d..fac41e6ba44 100644 --- a/app/models/group.rb +++ b/app/models/group.rb @@ -356,6 +356,8 @@ class Group < Namespace end def max_member_access_for_user(user) + return GroupMember::NO_ACCESS unless user + return GroupMember::OWNER if user.admin? members_with_parents |