enhance(ios): sync iCloud every 5 minutes in background

This commit is contained in:
leizhe
2022-01-24 16:07:05 +08:00
committed by Andelf
parent 170b2e6f93
commit ae739d668d
2 changed files with 11 additions and 3 deletions

View File

@@ -721,9 +721,7 @@
(config/get-file-extension format))
file-path (str "/" path)
repo-dir (config/get-repo-dir repo)]
(p/let [_ (when (mobile-util/native-ios?)
(.downloadFilesFromiCloud mobile-util/download-icloud-files))
file-exists? (fs/file-exists? repo-dir file-path)
(p/let [file-exists? (fs/file-exists? repo-dir file-path)
file-content (when file-exists?
(fs/read-file repo-dir file-path))]
(when (and (db/page-empty? repo today-page)