Skip to content

Commit

Permalink
Swiftlint
Browse files Browse the repository at this point in the history
  • Loading branch information
weichsel committed Dec 22, 2023
1 parent 4b24bdf commit 859722d
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion Sources/ZIPFoundation/Archive+Reading.swift
Original file line number Diff line number Diff line change
Expand Up @@ -57,7 +57,7 @@ extension Archive {

let parentURL = url.deletingLastPathComponent()
let isAbsolutePath = (linkPath as NSString).isAbsolutePath
let linkURL = isAbsolutePath ? URL(fileURLWithPath: linkPath) : URL(fileURLWithPath: linkPath, relativeTo: parentURL)
let linkURL = URL(fileURLWithPath: linkPath, relativeTo: isAbsolutePath ? nil : parentURL)
let isContained = linkURL.isContained(in: parentURL)
guard isContained else { throw ArchiveError.uncontainedSymlink }

Expand Down

0 comments on commit 859722d

Please sign in to comment.