Skip to content

Commit f7a800c

Browse files
authored
fix(ios): writeFile failing on root folders (#2670)
1 parent 6a6cd8b commit f7a800c

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

ios/Capacitor/Capacitor/Plugins/Filesystem.swift

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -103,7 +103,7 @@ public class CAPFilesystemPlugin : CAPPlugin {
103103
}
104104

105105
do {
106-
if !FileManager.default.fileExists(atPath: fileUrl.deletingLastPathComponent().absoluteString) {
106+
if !FileManager.default.fileExists(atPath: fileUrl.deletingLastPathComponent().path) {
107107
if recursive {
108108
try FileManager.default.createDirectory(at: fileUrl.deletingLastPathComponent(), withIntermediateDirectories: recursive, attributes: nil)
109109
} else {

0 commit comments

Comments
 (0)