{"action":"created","comment":{"url":"https://api.github.com/repos/tumblr/XExtensionItem/pulls/comments/30170358","id":30170358,"diff_hunk":"@@ -22,37 +24,50 @@ @implementation XExtensionItemSource\n \n #pragma mark - Initialization\n \n-- (instancetype)initWithPlaceholderItem:(id)placeholderItem attachments:(NSArray *)attachments {\n+- (instancetype)initWithPlaceholderItem:(id)placeholderItem typeIdentifier:(NSString *)typeIdentifier itemBlock:(XExtensionItemProvidingBlock)activityItemBlock {\n     NSParameterAssert(placeholderItem);\n     \n     self = [super init];\n     if (self) {\n         _placeholderItem = placeholderItem;\n-        _attachments = [attachments copy];\n+        _activityItemBlock = [activityItemBlock copy];\n         \n-        _activityTypesToItemProviderBlocks = [[NSMutableDictionary alloc] init];\n-        _activityTypesToSubjects = [[NSMutableDictionary alloc] init];\n-        _activityTypesToThumbnailProviderBlocks = [[NSMutableDictionary alloc] init];\n+        if (typeIdentifier)\n+            _typeIdentifier = [typeIdentifier copy];\n+        else\n+            _typeIdentifier = [typeIdentifierForActivityItem(placeholderItem) copy];\n+        \n+        _additionalAttachmentsByActivityType = [[NSMutableDictionary alloc] init];\n+        _attributedContentTextByActivityType = [[NSMutableDictionary alloc] init];\n     }\n     \n     return self;\n }\n \n-- (instancetype)initWithPlaceholderData:(id)placeholderData\n-                     dataTypeIdentifier:(NSString *)dataTypeIdentifier\n-                            attachments:(NSArray/*<NSItemProvider>*/ *)attachments {\n-    NSParameterAssert(dataTypeIdentifier);\n-    \n-    self = [self initWithPlaceholderItem:placeholderData attachments:attachments];\n-    if (self) {\n-        _dataTypeIdentifier = [dataTypeIdentifier copy];\n+- (instancetype)initWithURL:(NSURL *)URL {\n+    if ([URL isFileURL]) {","path":"Pod/Classes/XExtensionItem.m","position":67,"original_position":67,"commit_id":"d23a480df95d76f1d063765b3ea82e914de3f2d0","original_commit_id":"d23a480df95d76f1d063765b3ea82e914de3f2d0","user":{"login":"irace","id":399560,"avatar_url":"https://avatars.githubusercontent.com/u/399560?v=3","gravatar_id":"","url":"https://api.github.com/users/irace","html_url":"https://github.com/irace","followers_url":"https://api.github.com/users/irace/followers","following_url":"https://api.github.com/users/irace/following{/other_user}","gists_url":"https://api.github.com/users/irace/gists{/gist_id}","starred_url":"https://api.github.com/users/irace/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/irace/subscriptions","organizations_url":"https://api.github.com/users/irace/orgs","repos_url":"https://api.github.com/users/irace/repos","events_url":"https://api.github.com/users/irace/events{/privacy}","received_events_url":"https://api.github.com/users/irace/received_events","type":"User","site_admin":false},"body":"/me is pwned","created_at":"2015-05-12T19:22:10Z","updated_at":"2015-05-12T19:22:10Z","html_url":"https://github.com/tumblr/XExtensionItem/pull/46#discussion_r30170358","pull_request_url":"https://api.github.com/repos/tumblr/XExtensionItem/pulls/46","_links":{"self":{"href":"https://api.github.com/repos/tumblr/XExtensionItem/pulls/comments/30170358"},"html":{"href":"https://github.com/tumblr/XExtensionItem/pull/46#discussion_r30170358"},"pull_request":{"href":"https://api.github.com/repos/tumblr/XExtensionItem/pulls/46"}}},"pull_request":{"url":"https://api.github.com/repos/tumblr/XExtensionItem/pulls/46","id":35181390,"html_url":"https://github.com/tumblr/XExtensionItem/pull/46","diff_url":"https://github.com/tumblr/XExtensionItem/pull/46.diff","patch_url":"https://github.com/tumblr/XExtensionItem/pull/46.patch","issue_url":"https://api.github.com/repos/tumblr/XExtensionItem/issues/46","number":46,"state":"open","locked":false,"title":"Revised XExtensionItemSource API","user":{"login":"AriX","id":398952,"avatar_url":"https://avatars.githubusercontent.com/u/398952?v=3","gravatar_id":"","url":"https://api.github.com/users/AriX","html_url":"https://github.com/AriX","followers_url":"https://api.github.com/users/AriX/followers","following_url":"https://api.github.com/users/AriX/following{/other_user}","gists_url":"https://api.github.com/users/AriX/gists{/gist_id}","starred_url":"https://api.github.com/users/AriX/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/AriX/subscriptions","organizations_url":"https://api.github.com/users/AriX/orgs","repos_url":"https://api.github.com/users/AriX/repos","events_url":"https://api.github.com/users/AriX/events{/privacy}","received_events_url":"https://api.github.com/users/AriX/received_events","type":"User","site_admin":false},"body":"As discussed in #43.\r\n\r\nDocumentation, fixed tests, and code review are still necessary before this should be merged. @irace ","created_at":"2015-05-11T23:48:56Z","updated_at":"2015-05-12T19:22:10Z","closed_at":null,"merged_at":null,"merge_commit_sha":"d60c94a1e4eec177fa9dfb93553166fd6cf6441d","assignee":null,"milestone":null,"commits_url":"https://api.github.com/repos/tumblr/XExtensionItem/pulls/46/commits","review_comments_url":"https://api.github.com/repos/tumblr/XExtensionItem/pulls/46/comments","review_comment_url":"https://api.github.com/repos/tumblr/XExtensionItem/pulls/comments{/number}","comments_url":"https://api.github.com/repos/tumblr/XExtensionItem/issues/46/comments","statuses_url":"https://api.github.com/repos/tumblr/XExtensionItem/statuses/d23a480df95d76f1d063765b3ea82e914de3f2d0","head":{"label":"AriX:master","ref":"master","sha":"d23a480df95d76f1d063765b3ea82e914de3f2d0","user":{"login":"AriX","id":398952,"avatar_url":"https://avatars.githubusercontent.com/u/398952?v=3","gravatar_id":"","url":"https://api.github.com/users/AriX","html_url":"https://github.com/AriX","followers_url":"https://api.github.com/users/AriX/followers","following_url":"https://api.github.com/users/AriX/following{/other_user}","gists_url":"https://api.github.com/users/AriX/gists{/gist_id}","starred_url":"https://api.github.com/users/AriX/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/AriX/subscriptions","organizations_url":"https://api.github.com/users/AriX/orgs","repos_url":"https://api.github.com/users/AriX/repos","events_url":"https://api.github.com/users/AriX/events{/privacy}","received_events_url":"https://api.github.com/users/AriX/received_events","type":"User","site_admin":false},"repo":{"id":35182575,"name":"XExtensionItem","full_name":"AriX/XExtensionItem","owner":{"login":"AriX","id":398952,"avatar_url":"https://avatars.githubusercontent.com/u/398952?v=3","gravatar_id":"","url":"https://api.github.com/users/AriX","html_url":"https://github.com/AriX","followers_url":"https://api.github.com/users/AriX/followers","following_url":"https://api.github.com/users/AriX/following{/other_user}","gists_url":"https://api.github.com/users/AriX/gists{/gist_id}","starred_url":"https://api.github.com/users/AriX/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/AriX/subscriptions","organizations_url":"https://api.github.com/users/AriX/orgs","repos_url":"https://api.github.com/users/AriX/repos","events_url":"https://api.github.com/users/AriX/events{/privacy}","received_events_url":"https://api.github.com/users/AriX/received_events","type":"User","site_admin":false},"private":false,"html_url":"https://github.com/AriX/XExtensionItem","description":"Easier sharing of structured data between iOS applications and share extensions","fork":true,"url":"https://api.github.com/repos/AriX/XExtensionItem","forks_url":"https://api.github.com/repos/AriX/XExtensionItem/forks","keys_url":"https://api.github.com/repos/AriX/XExtensionItem/keys{/key_id}","collaborators_url":"https://api.github.com/repos/AriX/XExtensionItem/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/AriX/XExtensionItem/teams","hooks_url":"https://api.github.com/repos/AriX/XExtensionItem/hooks","issue_events_url":"https://api.github.com/repos/AriX/XExtensionItem/issues/events{/number}","events_url":"https://api.github.com/repos/AriX/XExtensionItem/events","assignees_url":"https://api.github.com/repos/AriX/XExtensionItem/assignees{/user}","branches_url":"https://api.github.com/repos/AriX/XExtensionItem/branches{/branch}","tags_url":"https://api.github.com/repos/AriX/XExtensionItem/tags","blobs_url":"https://api.github.com/repos/AriX/XExtensionItem/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/AriX/XExtensionItem/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/AriX/XExtensionItem/git/refs{/sha}","trees_url":"https://api.github.com/repos/AriX/XExtensionItem/git/trees{/sha}","statuses_url":"https://api.github.com/repos/AriX/XExtensionItem/statuses/{sha}","languages_url":"https://api.github.com/repos/AriX/XExtensionItem/languages","stargazers_url":"https://api.github.com/repos/AriX/XExtensionItem/stargazers","contributors_url":"https://api.github.com/repos/AriX/XExtensionItem/contributors","subscribers_url":"https://api.github.com/repos/AriX/XExtensionItem/subscribers","subscription_url":"https://api.github.com/repos/AriX/XExtensionItem/subscription","commits_url":"https://api.github.com/repos/AriX/XExtensionItem/commits{/sha}","git_commits_url":"https://api.github.com/repos/AriX/XExtensionItem/git/commits{/sha}","comments_url":"https://api.github.com/repos/AriX/XExtensionItem/comments{/number}","issue_comment_url":"https://api.github.com/repos/AriX/XExtensionItem/issues/comments{/number}","contents_url":"https://api.github.com/repos/AriX/XExtensionItem/contents/{+path}","compare_url":"https://api.github.com/repos/AriX/XExtensionItem/compare/{base}...{head}","merges_url":"https://api.github.com/repos/AriX/XExtensionItem/merges","archive_url":"https://api.github.com/repos/AriX/XExtensionItem/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/AriX/XExtensionItem/downloads","issues_url":"https://api.github.com/repos/AriX/XExtensionItem/issues{/number}","pulls_url":"https://api.github.com/repos/AriX/XExtensionItem/pulls{/number}","milestones_url":"https://api.github.com/repos/AriX/XExtensionItem/milestones{/number}","notifications_url":"https://api.github.com/repos/AriX/XExtensionItem/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/AriX/XExtensionItem/labels{/name}","releases_url":"https://api.github.com/repos/AriX/XExtensionItem/releases{/id}","created_at":"2015-05-06T20:58:11Z","updated_at":"2015-05-08T00:38:11Z","pushed_at":"2015-05-12T19:21:47Z","git_url":"git://github.com/AriX/XExtensionItem.git","ssh_url":"git@github.com:AriX/XExtensionItem.git","clone_url":"https://github.com/AriX/XExtensionItem.git","svn_url":"https://github.com/AriX/XExtensionItem","homepage":"","size":928,"stargazers_count":0,"watchers_count":0,"language":"Objective-C","has_issues":false,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":1,"mirror_url":null,"open_issues_count":1,"forks":1,"open_issues":1,"watchers":0,"default_branch":"master"}},"base":{"label":"tumblr:master","ref":"master","sha":"cc5afed942fa80edf46d6baf7386bd23d695c016","user":{"login":"tumblr","id":366151,"avatar_url":"https://avatars.githubusercontent.com/u/366151?v=3","gravatar_id":"","url":"https://api.github.com/users/tumblr","html_url":"https://github.com/tumblr","followers_url":"https://api.github.com/users/tumblr/followers","following_url":"https://api.github.com/users/tumblr/following{/other_user}","gists_url":"https://api.github.com/users/tumblr/gists{/gist_id}","starred_url":"https://api.github.com/users/tumblr/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/tumblr/subscriptions","organizations_url":"https://api.github.com/users/tumblr/orgs","repos_url":"https://api.github.com/users/tumblr/repos","events_url":"https://api.github.com/users/tumblr/events{/privacy}","received_events_url":"https://api.github.com/users/tumblr/received_events","type":"Organization","site_admin":false},"repo":{"id":26869061,"name":"XExtensionItem","full_name":"tumblr/XExtensionItem","owner":{"login":"tumblr","id":366151,"avatar_url":"https://avatars.githubusercontent.com/u/366151?v=3","gravatar_id":"","url":"https://api.github.com/users/tumblr","html_url":"https://github.com/tumblr","followers_url":"https://api.github.com/users/tumblr/followers","following_url":"https://api.github.com/users/tumblr/following{/other_user}","gists_url":"https://api.github.com/users/tumblr/gists{/gist_id}","starred_url":"https://api.github.com/users/tumblr/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/tumblr/subscriptions","organizations_url":"https://api.github.com/users/tumblr/orgs","repos_url":"https://api.github.com/users/tumblr/repos","events_url":"https://api.github.com/users/tumblr/events{/privacy}","received_events_url":"https://api.github.com/users/tumblr/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/tumblr/XExtensionItem","description":"Easier sharing of structured data between iOS applications and share extensions","fork":false,"url":"https://api.github.com/repos/tumblr/XExtensionItem","forks_url":"https://api.github.com/repos/tumblr/XExtensionItem/forks","keys_url":"https://api.github.com/repos/tumblr/XExtensionItem/keys{/key_id}","collaborators_url":"https://api.github.com/repos/tumblr/XExtensionItem/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/tumblr/XExtensionItem/teams","hooks_url":"https://api.github.com/repos/tumblr/XExtensionItem/hooks","issue_events_url":"https://api.github.com/repos/tumblr/XExtensionItem/issues/events{/number}","events_url":"https://api.github.com/repos/tumblr/XExtensionItem/events","assignees_url":"https://api.github.com/repos/tumblr/XExtensionItem/assignees{/user}","branches_url":"https://api.github.com/repos/tumblr/XExtensionItem/branches{/branch}","tags_url":"https://api.github.com/repos/tumblr/XExtensionItem/tags","blobs_url":"https://api.github.com/repos/tumblr/XExtensionItem/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/tumblr/XExtensionItem/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/tumblr/XExtensionItem/git/refs{/sha}","trees_url":"https://api.github.com/repos/tumblr/XExtensionItem/git/trees{/sha}","statuses_url":"https://api.github.com/repos/tumblr/XExtensionItem/statuses/{sha}","languages_url":"https://api.github.com/repos/tumblr/XExtensionItem/languages","stargazers_url":"https://api.github.com/repos/tumblr/XExtensionItem/stargazers","contributors_url":"https://api.github.com/repos/tumblr/XExtensionItem/contributors","subscribers_url":"https://api.github.com/repos/tumblr/XExtensionItem/subscribers","subscription_url":"https://api.github.com/repos/tumblr/XExtensionItem/subscription","commits_url":"https://api.github.com/repos/tumblr/XExtensionItem/commits{/sha}","git_commits_url":"https://api.github.com/repos/tumblr/XExtensionItem/git/commits{/sha}","comments_url":"https://api.github.com/repos/tumblr/XExtensionItem/comments{/number}","issue_comment_url":"https://api.github.com/repos/tumblr/XExtensionItem/issues/comments{/number}","contents_url":"https://api.github.com/repos/tumblr/XExtensionItem/contents/{+path}","compare_url":"https://api.github.com/repos/tumblr/XExtensionItem/compare/{base}...{head}","merges_url":"https://api.github.com/repos/tumblr/XExtensionItem/merges","archive_url":"https://api.github.com/repos/tumblr/XExtensionItem/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/tumblr/XExtensionItem/downloads","issues_url":"https://api.github.com/repos/tumblr/XExtensionItem/issues{/number}","pulls_url":"https://api.github.com/repos/tumblr/XExtensionItem/pulls{/number}","milestones_url":"https://api.github.com/repos/tumblr/XExtensionItem/milestones{/number}","notifications_url":"https://api.github.com/repos/tumblr/XExtensionItem/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/tumblr/XExtensionItem/labels{/name}","releases_url":"https://api.github.com/repos/tumblr/XExtensionItem/releases{/id}","created_at":"2014-11-19T16:00:02Z","updated_at":"2015-05-12T14:16:56Z","pushed_at":"2015-05-11T23:55:38Z","git_url":"git://github.com/tumblr/XExtensionItem.git","ssh_url":"git@github.com:tumblr/XExtensionItem.git","clone_url":"https://github.com/tumblr/XExtensionItem.git","svn_url":"https://github.com/tumblr/XExtensionItem","homepage":"","size":1887,"stargazers_count":28,"watchers_count":28,"language":"Objective-C","has_issues":true,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":2,"mirror_url":null,"open_issues_count":10,"forks":2,"open_issues":10,"watchers":28,"default_branch":"master"}},"_links":{"self":{"href":"https://api.github.com/repos/tumblr/XExtensionItem/pulls/46"},"html":{"href":"https://github.com/tumblr/XExtensionItem/pull/46"},"issue":{"href":"https://api.github.com/repos/tumblr/XExtensionItem/issues/46"},"comments":{"href":"https://api.github.com/repos/tumblr/XExtensionItem/issues/46/comments"},"review_comments":{"href":"https://api.github.com/repos/tumblr/XExtensionItem/pulls/46/comments"},"review_comment":{"href":"https://api.github.com/repos/tumblr/XExtensionItem/pulls/comments{/number}"},"commits":{"href":"https://api.github.com/repos/tumblr/XExtensionItem/pulls/46/commits"},"statuses":{"href":"https://api.github.com/repos/tumblr/XExtensionItem/statuses/d23a480df95d76f1d063765b3ea82e914de3f2d0"}}}}