Closed
Description
@tomholub ability to throw from
var
variable was added to the Swift recently:var activeUser: UserRealmObject { get throws { guard let user = user else { throw AppErr... } return user } }
This looks good. Probably for another issue/PR?
The advantage is that an exception can be captured and handled (in the general error handling somewhere in VC, wherever user action was initiated) while a forced unwrap cannot.
Originally posted by @tomholub in #1030 (comment)