This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
public func getParticipantsState(_ id: String, completion: @escaping (Bool) -> Void) { | |
guard let myEmail = UserDefaults.standard.value(forKey: "email") as? String else { | |
return | |
} | |
let currentEmail = DatabaseManager.safeEmail(emailAddress: myEmail) | |
database.child("\(id)/participants").observeSingleEvent(of: .value) { snapshot in | |
guard let values = snapshot.value as? [String:Bool] else { | |
completion(false) | |
return |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
class WorkInfo: Object{ | |
@objc dynamic var title: String? | |
@objc dynamic var content: String? | |
let seq = RealmOptional<Int>() | |
// ... | |
} |