If there is no roles at all, unhandled System.NullReferenceException is thrown when trying to create a new user
MvcMembership\Views\UserAdministration\CreateUser.cshtml:line 21
<fieldset>
<h3 class="mvcMembership">Initial Roles</h3>
@for(var i = 0; i < Model.InitialRoles.Count; i++){
var role = Model.InitialRoles.ElementAt(i);
<div>
<input name="InitialRoles[@i].Key" type="hidden" value="@role.Key" />
<label>@Html.CheckBox("InitialRoles[" + i + "].Value", role.Value) @role.Key</label>
</div>
}
</fieldset>
If there is no roles at all, unhandled System.NullReferenceException is thrown when trying to create a new user MvcMembership\Views\UserAdministration\CreateUser.cshtml:line 21