COVIDSafe code from version 1.4 (#3)

This commit is contained in:
COVIDSafe Support 2020-05-26 17:13:26 +10:00 committed by GitHub
parent 56c93f2079
commit b2e0c5b34c
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
33 changed files with 6865 additions and 481 deletions

View file

@ -13,11 +13,12 @@ final class UploadHelper {
public static func uploadEncounterData(pin: String?, _ result: @escaping (UploadResult) -> Void) {
let keychain = KeychainSwift()
guard let appDelegate = UIApplication.shared.delegate as? AppDelegate else {
guard let managedContext = EncounterDB.shared.persistentContainer?.viewContext else {
result(.Failed)
return
}
let managedContext = appDelegate.persistentContainer.viewContext
let recordsFetchRequest: NSFetchRequest<Encounter> = Encounter.fetchRequestForRecords()