问题
I have a requirement where I need to use NSUSerActivity and Corespotlight together. I see duplicate search results in spotlight even after I set relatedUniqueIdentifier =uniqueidentifer.
Here is the steps I implemented in my project.
1) Create all CSSearchableItems in appdeleagte didFinishLaunchingWithOptions method.
2) Create NSUSerActivity in specific viewcontroller where relatedUniqueIdentifier = uniqueidentifer(CSSearchableItem)
Appreciate your help.
回答1:
The issue got resolved after adding requiredUserInfoKeys in NSUSerActivity.
来源:https://stackoverflow.com/questions/34732192/duplicate-search-results-in-spotlight