Change from flatMap to new compactMap rename in Xcode 9.3.

This commit is contained in:
Daniel Jalkut
2018-01-27 21:50:48 -05:00
parent 2d7d903bca
commit d7f13ca4be
26 changed files with 152 additions and 35 deletions

View File

@@ -36,7 +36,7 @@ final class DeleteFromSidebarCommand: UndoableCommand {
self.undoActionName = actionName
self.undoManager = undoManager
let itemSpecifiers = nodesToDelete.flatMap{ SidebarItemSpecifier(node: $0) }
let itemSpecifiers = nodesToDelete.compactMap{ SidebarItemSpecifier(node: $0) }
guard !itemSpecifiers.isEmpty else {
return nil
}