mirror of
https://github.com/bitwarden/mobile.git
synced 2024-11-26 12:16:07 +01:00
null check on parts
This commit is contained in:
parent
3b7078e565
commit
661cd79654
@ -133,9 +133,9 @@ namespace Bit.Core.Services
|
|||||||
Id = c.Id,
|
Id = c.Id,
|
||||||
OrganizationId = c.OrganizationId
|
OrganizationId = c.OrganizationId
|
||||||
};
|
};
|
||||||
CoreHelpers.NestedTraverse(nodes, 0,
|
var parts = c.Name != null ?
|
||||||
Regex.Replace(c.Name, "^\\/+|\\/+$", string.Empty).Split(NestingDelimiter),
|
Regex.Replace(c.Name, "^\\/+|\\/+$", string.Empty).Split(NestingDelimiter) : new string[] { };
|
||||||
collectionCopy, null, NestingDelimiter);
|
CoreHelpers.NestedTraverse(nodes, 0, parts, collectionCopy, null, NestingDelimiter);
|
||||||
}
|
}
|
||||||
return nodes;
|
return nodes;
|
||||||
}
|
}
|
||||||
|
@ -127,9 +127,9 @@ namespace Bit.Core.Services
|
|||||||
Id = f.Id,
|
Id = f.Id,
|
||||||
RevisionDate = f.RevisionDate
|
RevisionDate = f.RevisionDate
|
||||||
};
|
};
|
||||||
CoreHelpers.NestedTraverse(nodes, 0,
|
var parts = f.Name != null ?
|
||||||
Regex.Replace(f.Name, "^\\/+|\\/+$", string.Empty).Split(NestingDelimiter),
|
Regex.Replace(f.Name, "^\\/+|\\/+$", string.Empty).Split(NestingDelimiter) : new string[] { };
|
||||||
folderCopy, null, NestingDelimiter);
|
CoreHelpers.NestedTraverse(nodes, 0, parts, folderCopy, null, NestingDelimiter);
|
||||||
}
|
}
|
||||||
return nodes;
|
return nodes;
|
||||||
}
|
}
|
||||||
|
Loading…
Reference in New Issue
Block a user