Skip to content

Commit 0774ce3

Browse files
ferologicsferologics
authored andcommitted
🛠 Address review comment
1 parent f5420e9 commit 0774ce3

1 file changed

Lines changed: 1 addition & 6 deletions

File tree

Sources/XcodeProj/Project/XcodeProj.swift

Lines changed: 1 addition & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -130,12 +130,7 @@ extension XcodeProj: Writable {
130130
/// - Parameter override: if workspace should be overridden. Default is true.
131131
/// If false will throw error if workspace already exists at the given path.
132132
public func writeWorkspace(path: Path, override: Bool = true) throws {
133-
134-
// prevent overwriting identical workspace data
135-
if let prevData = try? XCWorkspaceData(path: path), prevData == workspace.data {
136-
return
137-
}
138-
133+
guard workspace.data != (try? XCWorkspaceData(path: path)) else { return }
139134
try workspace.write(path: XcodeProj.workspacePath(path), override: override)
140135
}
141136

0 commit comments

Comments
 (0)