From abd50bff4219d6cf87f6b4c6fe35a601f3ed121e Mon Sep 17 00:00:00 2001 From: Jackson Harper Date: Fri, 27 Jan 2023 14:51:15 +0800 Subject: [PATCH] Set the author when updating page data --- .../DataService/Mutations/UpdateLinkedItemTitle.swift | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/apple/OmnivoreKit/Sources/Services/DataService/Mutations/UpdateLinkedItemTitle.swift b/apple/OmnivoreKit/Sources/Services/DataService/Mutations/UpdateLinkedItemTitle.swift index 09b859c28..fc9c54231 100644 --- a/apple/OmnivoreKit/Sources/Services/DataService/Mutations/UpdateLinkedItemTitle.swift +++ b/apple/OmnivoreKit/Sources/Services/DataService/Mutations/UpdateLinkedItemTitle.swift @@ -21,6 +21,7 @@ extension DataService { itemID: itemID, objectID: linkedItem.objectID, title: title, + author: author, description: description ) } @@ -30,6 +31,7 @@ extension DataService { itemID: String, objectID: NSManagedObjectID, title: String, + author: String?, description: String ) { enum MutationResult { @@ -48,7 +50,7 @@ extension DataService { let mutation = Selection.Mutation { try $0.updatePage( - input: .init(description: OptionalArgument(description), pageId: itemID, title: OptionalArgument(title)), + input: .init(byline: OptionalArgument(author), description: OptionalArgument(description), pageId: itemID, title: OptionalArgument(title)), selection: selection ) }