kopia lustrzana https://gitlab.com/mysocialportal/relatica
Add check for when can't find parent ID and write to severe error log
rodzic
04fa5395d3
commit
5c0677b923
|
@ -283,6 +283,11 @@ class EntryManagerService extends ChangeNotifier {
|
|||
final parentParentPostId = _postNodes.containsKey(item.parentId)
|
||||
? item.parentId
|
||||
: _parentPostIds[item.parentId];
|
||||
if (_postNodes[parentParentPostId] == null) {
|
||||
_logger.severe(
|
||||
'Error finding parent ${item.parentId} for entry ${item.id}');
|
||||
continue;
|
||||
}
|
||||
final parentPostNode = _postNodes[parentParentPostId]!;
|
||||
postNodesToReturn.add(parentPostNode);
|
||||
_parentPostIds[item.id] = parentPostNode.id;
|
||||
|
|
Ładowanie…
Reference in New Issue