refactor: 精简代码

This commit is contained in:
Argo-Tianyi 2022-03-26 11:14:21 +08:00
parent 3f9555273b
commit 13e5b282e9
1 changed files with 1 additions and 1 deletions

View File

@ -132,7 +132,7 @@ namespace BootstrapAdmin.Web.Shared
{ {
var user = UsersService.GetUserByUserName(UserName); var user = UsersService.GetUserByUserName(UserName);
Context.UserName = UserName; Context.UserName = UserName;
Context.DisplayName = user?.DisplayName ?? "未注册账户"; ; Context.DisplayName = user?.DisplayName ?? "未注册账户";
Icon = string.IsNullOrEmpty(user?.Icon) ? "/images/uploader/default.jpg" : GetIcon(user.Icon); Icon = string.IsNullOrEmpty(user?.Icon) ? "/images/uploader/default.jpg" : GetIcon(user.Icon);
MenuItems = NavigationsService.GetAllMenus(UserName).ToMenus(); MenuItems = NavigationsService.GetAllMenus(UserName).ToMenus();