Skip to content

Commit be6bed3

Browse files
committed
Renamed
1 parent 0181a8c commit be6bed3

File tree

1 file changed

+2
-4
lines changed

1 file changed

+2
-4
lines changed

Documentation/Index.md

Lines changed: 2 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -262,10 +262,8 @@ If you have bundled it in your application, you can use FileManager to copy it t
262262

263263
```swift
264264
func copyDatabaseIfNeeded(sourcePath: String) -> Bool {
265-
let path = NSSearchPathForDirectoriesInDomains(
266-
.documentDirectory, .userDomainMask, true
267-
).first!
268-
let destinationPath = destinationPath + "/db.sqlite3"
265+
let documents = NSSearchPathForDirectoriesInDomains(.documentDirectory, .userDomainMask, true).first!
266+
let destinationPath = documents + "/db.sqlite3"
269267
let exists = FileManager.default.fileExists(atPath: destinationPath)
270268
guard !exists else { return false }
271269
do {

0 commit comments

Comments
 (0)