Browse Source

fix(modules/docs): null exception problem

pull/12751/head
Berkan Sasmaz 4 years ago
parent
commit
c44fa07215
No known key found for this signature in database GPG Key ID: 4E387A3A3BCC339B
  1. 4
      modules/docs/src/Volo.Docs.Web/Pages/Documents/Project/Index.cshtml.cs

4
modules/docs/src/Volo.Docs.Web/Pages/Documents/Project/Index.cshtml.cs

@ -78,7 +78,7 @@ namespace Volo.Docs.Pages.Documents.Project
public bool FullSearchEnabled { get; set; }
public bool IsLatestVersion => Version == LatestVersionInfo.Version;
public bool IsLatestVersion { get; private set; }
private const int MaxDescriptionMetaTagLength = 200;
private readonly IDocumentAppService _documentAppService;
@ -335,6 +335,8 @@ namespace Volo.Docs.Pages.Documents.Project
Value = CreateVersionLink(LatestVersionInfo, v.Version, DocumentName),
Selected = v.IsSelected
}).ToList();
IsLatestVersion = Version == LatestVersionInfo.Version;
}
private VersionInfoViewModel GetLatestVersionInfo(List<VersionInfoViewModel> versions)

Loading…
Cancel
Save