Fixes an issue with missing _key in member search

This commit is contained in:
perploug
2013-10-29 22:10:56 +01:00
parent a7f5576fee
commit d8a8556598
2 changed files with 2 additions and 2 deletions

View File

@@ -1,6 +1,6 @@
//used for the member picker dialog
angular.module("umbraco").controller("Umbraco.Dialogs.MemberPickerController",
function($scope, eventsService, searchService, $log) {
function($scope, eventsService, entityResource, searchService, $log) {
var dialogOptions = $scope.$parent.dialogOptions;
$scope.dialogTreeEventHandler = $({});
$scope.results = [];

View File

@@ -226,7 +226,7 @@ namespace Umbraco.Web.Editors
{
m.AdditionalData["Email"] = results.First(x => x.Id.ToInvariantString() == m.Id.ToString()).Fields["email"];
}
if (searchResult.Fields["__key"] != null)
if (searchResult.Fields.ContainsKey("__key") && searchResult.Fields["__key"] != null)
{
Guid key;
if (Guid.TryParse(searchResult.Fields["__key"], out key))