// // PersistentThingExtension.swift // JustOneThing // // Created by Alan Francis on 15/07/2023. // import CoreData extension PersistentThing { var asThing: Thing { get { Thing(text: self.text ?? "[no text]", createdAt: self.createdAt ?? Date.distantPast) } } static var request: NSFetchRequest { get { return NSFetchRequest(entityName: PersistentThing.entity().name!) } } }