File tree Expand file tree Collapse file tree 2 files changed +2
-2
lines changed Expand file tree Collapse file tree 2 files changed +2
-2
lines changed Original file line number Diff line number Diff line change @@ -199,7 +199,7 @@ extension NSString {
199
199
#endif
200
200
}
201
201
202
- public static func pathWithComponents ( _ components: [ String ] ) -> String {
202
+ public static func path ( withComponents components: [ String ] ) -> String {
203
203
var result = " "
204
204
for comp in components. prefix ( components. count - 1 ) {
205
205
result = result. _stringByAppendingPathComponent ( comp. _stringByFixingSlashes ( ) , doneAppending: false )
Original file line number Diff line number Diff line change @@ -705,7 +705,7 @@ extension NSURL {
705
705
/* The following methods work on the path portion of a URL in the same manner that the NSPathUtilities methods on NSString do.
706
706
*/
707
707
open class func fileURL( withPathComponents components: [ String ] ) -> URL ? {
708
- let path = NSString . pathWithComponents ( components)
708
+ let path = NSString . path ( withComponents : components)
709
709
if components. last == " / " {
710
710
return URL ( fileURLWithPath: path, isDirectory: true )
711
711
} else {
You can’t perform that action at this time.
0 commit comments