Make exportDictionary and internalDictionary private vars instead of functions in FeedPasteboardWriter.
This commit is contained in:
parent
c4e97c028b
commit
3a5741a5dd
|
@ -172,9 +172,9 @@ extension Feed: PasteboardWriterOwner {
|
|||
case .URL:
|
||||
plist = feed.url
|
||||
case FeedPasteboardWriter.feedUTIType:
|
||||
plist = exportDictionary()
|
||||
plist = exportDictionary
|
||||
case FeedPasteboardWriter.feedUTIInternalType:
|
||||
plist = internalDictionary()
|
||||
plist = internalDictionary
|
||||
default:
|
||||
plist = nil
|
||||
}
|
||||
|
@ -185,13 +185,15 @@ extension Feed: PasteboardWriterOwner {
|
|||
|
||||
private extension FeedPasteboardWriter {
|
||||
|
||||
func exportDictionary() -> [String: String] {
|
||||
let pasteboardFeed = PasteboardFeed(url: feed.url, feedID: feed.feedID, homePageURL: feed.homePageURL, name: feed.name, editedName: feed.editedName, accountID: feed.account?.accountID)
|
||||
var pasteboardFeed: PasteboardFeed {
|
||||
return PasteboardFeed(url: feed.url, feedID: feed.feedID, homePageURL: feed.homePageURL, name: feed.name, editedName: feed.editedName, accountID: feed.account?.accountID)
|
||||
}
|
||||
|
||||
var exportDictionary: PasteboardFeedDictionary {
|
||||
return pasteboardFeed.exportDictionary()
|
||||
}
|
||||
|
||||
func internalDictionary() -> [String: Any] {
|
||||
let pasteboardFeed = PasteboardFeed(url: feed.url, feedID: feed.feedID, homePageURL: feed.homePageURL, name: feed.name, editedName: feed.editedName, accountID: feed.account?.accountID)
|
||||
var internalDictionary: PasteboardFeedDictionary {
|
||||
return pasteboardFeed.internalDictionary()
|
||||
}
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue