This commit is contained in:
@@ -6,6 +6,7 @@ using AyaNova.Api.ControllerHelpers;
|
|||||||
using AyaNova.Models;
|
using AyaNova.Models;
|
||||||
using System.Collections.Generic;
|
using System.Collections.Generic;
|
||||||
using Newtonsoft.Json.Linq;
|
using Newtonsoft.Json.Linq;
|
||||||
|
using Microsoft.Extensions.Logging;
|
||||||
|
|
||||||
namespace AyaNova.Biz
|
namespace AyaNova.Biz
|
||||||
{
|
{
|
||||||
@@ -329,6 +330,18 @@ namespace AyaNova.Biz
|
|||||||
TrackRequestedKey(param);
|
TrackRequestedKey(param);
|
||||||
#endif
|
#endif
|
||||||
var ret = await ct.TranslationItem.Where(z => z.TranslationId == UserTranslationId && param.Contains(z.Key)).AsNoTracking().ToDictionaryAsync(z => z.Key, z => z.Display);
|
var ret = await ct.TranslationItem.Where(z => z.TranslationId == UserTranslationId && param.Contains(z.Key)).AsNoTracking().ToDictionaryAsync(z => z.Key, z => z.Display);
|
||||||
|
#if (DEBUG)
|
||||||
|
if(ret.Count!=param.Count){
|
||||||
|
ILogger log = AyaNova.Util.ApplicationLogging.CreateLogger<TranslationBiz>();
|
||||||
|
|
||||||
|
var missingItems = param.Where(p => ret.All(p2 => p2.Key != p));
|
||||||
|
|
||||||
|
log.LogError($"********* GetSubsetAsync Non existant keys requested: {string.Join( ",", missingItems)}");
|
||||||
|
|
||||||
|
|
||||||
|
}
|
||||||
|
#endif
|
||||||
|
|
||||||
return ret.ToList();
|
return ret.ToList();
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user