fixes a null ref

vnext
Paul Schneider 8 years ago
parent 537dda7721
commit 85c6c9ebcf
1 changed files with 11 additions and 11 deletions

@ -2,7 +2,7 @@
<div class="performer @(Model.Active?"active":"inactive")"> <div class="performer @(Model.Active?"active":"inactive")">
<img src="~/Avatars/@(Model.Performer.UserName).xs.png" alt="avatar"> <img src="~/Avatars/@(Model.Performer?.UserName).xs.png" alt="avatar">
@Model.Performer?.UserName @Model.Performer?.UserName
@ -17,23 +17,23 @@
@if (Model.WebSite!=null) { @if (Model.WebSite!=null) {
<li>@SR["WebSite"]: @Model.WebSite</li> <li>@SR["WebSite"]: @Model.WebSite</li>
} }
@if (Model.Performer.Posts!=null) { @if (Model.Performer != null) {
@if (Model.Performer.Posts!=null) {
<li> <a asp-controller="Blogspot" asp-action="UserPosts" <li> <a asp-controller="Blogspot" asp-action="UserPosts"
asp-route-id="@Model.Performer.UserName">@SR["His blog"]</a> asp-route-id="@Model.Performer.UserName">@SR["His blog"]</a>
</li> </li>
} }
@if (Model.Performer != null) { @if (!string.IsNullOrEmpty(
@if (!string.IsNullOrEmpty( Model.Performer.DedicatedGoogleCalendar))
Model.Performer.DedicatedGoogleCalendar)) {
{
<li> @SR["Exposes his Google calendar!"] <li> @SR["Exposes his Google calendar!"]
</li> </li>
} }
@if (Model.Performer.Devices?.Count>0) @if (Model.Performer.Devices?.Count>0)
{ {
<li> @SR["Uses the mobile application, and receives push notifications"] <li> @SR["Uses the mobile application, and receives push notifications"]
</li> </li>
} }
} }
</ul> </ul>

Loading…