Fixed creating NSURL from folder and filename

This commit is contained in:
dankito 2020-07-30 14:39:58 +02:00
parent 20cd16e509
commit c476483f87
1 changed files with 1 additions and 1 deletions

View File

@ -6,7 +6,7 @@ import platform.Foundation.*
actual class File actual constructor(path: String) : NSURL(fileURLWithPath = path) {
actual constructor(folder: File, filename: String)
: this(NSURL(string = filename, relativeToURL = folder).absoluteString ?: "") // TODO: or use 'fileURLWithPath'?
: this(folder.URLByAppendingPathComponent(filename)?.path ?: "")
actual fun getAbsolutePath(): String {