mirror of
https://github.com/halejohn/Cloudreve.git
synced 2026-01-26 09:34:57 +08:00
Ready for release
This commit is contained in:
@@ -108,7 +108,10 @@ func (user *User) GetRemainingCapacity() uint64 {
|
||||
|
||||
// GetPolicyID 获取用户当前的存储策略ID
|
||||
func (user *User) GetPolicyID(prefer uint) uint {
|
||||
return user.Group.PolicyList[0]
|
||||
if len(user.Group.PolicyList) > 0 {
|
||||
return user.Group.PolicyList[0]
|
||||
}
|
||||
return 0
|
||||
}
|
||||
|
||||
// GetUserByID 用ID获取用户
|
||||
|
||||
Reference in New Issue
Block a user