Improved date handling (DurationComponents)
This commit is contained in:
@@ -91,6 +91,16 @@ struct RecipeDetail: Codable {
|
||||
recipeInstructions = []
|
||||
nutrition = [:]
|
||||
}
|
||||
|
||||
func getKeywordsArray() -> [String] {
|
||||
return keywords.components(separatedBy: ",")
|
||||
}
|
||||
|
||||
mutating func setKeywordsFromArray(_ keywordsArray: [String]) {
|
||||
if !self.keywords.isEmpty {
|
||||
self.keywords = keywordsArray.joined(separator: ",")
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
extension RecipeDetail {
|
||||
|
||||
Reference in New Issue
Block a user