Gate code that only should be used on iOS
This commit is contained in:
parent
c1460d3df3
commit
8f78d549c9
@ -159,9 +159,11 @@ class ActivityManager {
|
|||||||
return
|
return
|
||||||
}
|
}
|
||||||
|
|
||||||
|
#if os(iOS)
|
||||||
if let article = readingArticle, activityFeedId == article.feedID {
|
if let article = readingArticle, activityFeedId == article.feedID {
|
||||||
updateReadArticleSearchAttributes(with: article)
|
updateReadArticleSearchAttributes(with: article)
|
||||||
}
|
}
|
||||||
|
#endif
|
||||||
|
|
||||||
if activityFeedId == feed.feedID {
|
if activityFeedId == feed.feedID {
|
||||||
updateSelectingActivityFeedSearchAttributes(with: feed)
|
updateSelectingActivityFeedSearchAttributes(with: feed)
|
||||||
@ -208,6 +210,7 @@ private extension ActivityManager {
|
|||||||
return activity
|
return activity
|
||||||
}
|
}
|
||||||
|
|
||||||
|
#if os(iOS)
|
||||||
func updateReadArticleSearchAttributes(with article: Article) {
|
func updateReadArticleSearchAttributes(with article: Article) {
|
||||||
|
|
||||||
let attributeSet = CSSearchableItemAttributeSet(itemContentType: kUTTypeCompositeContent as String)
|
let attributeSet = CSSearchableItemAttributeSet(itemContentType: kUTTypeCompositeContent as String)
|
||||||
@ -223,6 +226,7 @@ private extension ActivityManager {
|
|||||||
readingActivity?.needsSave = true
|
readingActivity?.needsSave = true
|
||||||
|
|
||||||
}
|
}
|
||||||
|
#endif
|
||||||
|
|
||||||
func makeKeywords(_ article: Article) -> [String] {
|
func makeKeywords(_ article: Article) -> [String] {
|
||||||
let feedNameKeywords = makeKeywords(article.feed?.nameForDisplay)
|
let feedNameKeywords = makeKeywords(article.feed?.nameForDisplay)
|
||||||
|
Loading…
x
Reference in New Issue
Block a user