Skip to content

Commit ba76348

Browse files
authored
Merge pull request #99 from iandyh/ownership-2
system account user is also an admin
2 parents 3b7c61a + c2206cb commit ba76348

File tree

1 file changed

+5
-0
lines changed

1 file changed

+5
-0
lines changed

shibuya/model/user.go

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -48,5 +48,10 @@ func (a *Account) IsAdmin() bool {
4848
}
4949
}
5050
}
51+
// systemuser is the user used for LDAP auth. If a user login with that account
52+
// we can also treat it as a admin
53+
if a.Name == config.SC.AuthConfig.SystemUser {
54+
return true
55+
}
5156
return false
5257
}

0 commit comments

Comments
 (0)