修改获取用户资料接口

FileMonitor
洁 任 2024-11-14 11:41:33 +08:00
parent 289ad5e56d
commit f2f1657060
1 changed files with 2 additions and 2 deletions

View File

@ -46,9 +46,9 @@ namespace OpenAuth.WebApi.Controllers
try try
{ {
resp.Result = _authStrategyContext.User.MapTo<UserView>(); resp.Result = _authStrategyContext.User.MapTo<UserView>();
if (_authStrategyContext.Orgs != null) if (_authStrategyContext.Orgs.Count>0)
{ {
var orgLevel = _authStrategyContext.Orgs.Min(a => a.Level); var orgLevel = _authStrategyContext.Orgs?.Min(a => a.Level);
resp.Result.OrgMaxLevel = orgLevel.ToString(); resp.Result.OrgMaxLevel = orgLevel.ToString();
} }
} }