Skip to content

Commit

Permalink
Merge pull request #58 from swift-xcode/automatic_filereference_type
Browse files Browse the repository at this point in the history
Automatic file reference type
  • Loading branch information
yonaskolb authored Aug 27, 2017
2 parents 99c1c50 + 93658b7 commit 0b752d8
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions Sources/PBXFileReference.swift
Original file line number Diff line number Diff line change
Expand Up @@ -41,7 +41,7 @@ public class PBXFileReference: PBXObject, Hashable {
includeInIndex: Int? = nil) {
self.fileEncoding = fileEncoding
self.explicitFileType = explicitFileType
self.lastKnownFileType = lastKnownFileType
self.lastKnownFileType = lastKnownFileType ?? path.flatMap { PBXFileReference.fileType(path: Path($0)) }
self.name = name
self.path = path
self.sourceTree = sourceTree
Expand Down Expand Up @@ -118,7 +118,7 @@ extension PBXFileReference {
///
/// - Parameter path: path whose file type will be returned.
/// - Returns: file type (if supported).
static func fileType(path: Path) -> String? {
public static func fileType(path: Path) -> String? {
return path.extension.flatMap({fileTypeHash[$0]})
}

Expand Down

0 comments on commit 0b752d8

Please sign in to comment.