mirror of
https://github.com/rmcrackan/Libation.git
synced 2026-10-22 13:45:07 -04:00
Fix NRE when item has no category ladders (#715)
This commit is contained in:
1 parent
f175b7592e
commit
736d7c4a5f
1 file changed
+3
-1
@@ -23,9 +23,11 @@ namespace DtoImporterService
|
||||
loadLocal_categories();
|
||||
|
||||
// upsert
|
||||
//Import item may not have no (null) categories
|
||||
var categoryLadders = importItems
|
||||
.Where(i => i.DtoItem.CategoryLadders is not null)
|
||||
.SelectMany(i => i.DtoItem.CategoryLadders)
|
||||
.Select(cl => cl.Ladder)
|
||||
.Select(cl => cl?.Ladder)
|
||||
.Where(l => l?.Length > 0)
|
||||
.ToList();
|
||||
|
||||
|
||||
Reference in new issue
Block a user