{"action":"created","comment":{"url":"https://api.github.com/repos/friendica/friendica/pulls/comments/227336687","pull_request_review_id":167352493,"id":227336687,"node_id":"MDI0OlB1bGxSZXF1ZXN0UmV2aWV3Q29tbWVudDIyNzMzNjY4Nw==","diff_hunk":"@@ -895,10 +895,14 @@ public static function update(array $fields, array $condition)\n \t\t\t\t}\n \t\t\t}\n \n-\t\t\tif (!empty($tags)) {\n-\t\t\t\tTerm::insertFromTagFieldByItemId($item['id'], $tags);\n-\t\t\t\tif (!empty($item['tag'])) {\n-\t\t\t\t\tDBA::update('item', ['tag' => ''], ['id' => $item['id']]);\n+\t\t\tif (!is_null($tags)) {","path":"src/Model/Item.php","position":17,"original_position":17,"commit_id":"d06ddffbb7a2b772a5914e141234b180e02079b0","original_commit_id":"d06ddffbb7a2b772a5914e141234b180e02079b0","user":{"login":"annando","id":844208,"node_id":"MDQ6VXNlcjg0NDIwOA==","avatar_url":"https://avatars1.githubusercontent.com/u/844208?v=4","gravatar_id":"","url":"https://api.github.com/users/annando","html_url":"https://github.com/annando","followers_url":"https://api.github.com/users/annando/followers","following_url":"https://api.github.com/users/annando/following{/other_user}","gists_url":"https://api.github.com/users/annando/gists{/gist_id}","starred_url":"https://api.github.com/users/annando/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/annando/subscriptions","organizations_url":"https://api.github.com/users/annando/orgs","repos_url":"https://api.github.com/users/annando/repos","events_url":"https://api.github.com/users/annando/events{/privacy}","received_events_url":"https://api.github.com/users/annando/received_events","type":"User","site_admin":false},"body":"How do you decide whether the tags should be emptied or if the update doesn't contain the tags at all? Example: When you only update the \"body\", this part of the code mustn't be executed.","created_at":"2018-10-23T10:58:10Z","updated_at":"2018-10-23T10:58:10Z","html_url":"https://github.com/friendica/friendica/pull/6003#discussion_r227336687","pull_request_url":"https://api.github.com/repos/friendica/friendica/pulls/6003","author_association":"COLLABORATOR","_links":{"self":{"href":"https://api.github.com/repos/friendica/friendica/pulls/comments/227336687"},"html":{"href":"https://github.com/friendica/friendica/pull/6003#discussion_r227336687"},"pull_request":{"href":"https://api.github.com/repos/friendica/friendica/pulls/6003"}}},"pull_request":{"url":"https://api.github.com/repos/friendica/friendica/pulls/6003","id":224968217,"node_id":"MDExOlB1bGxSZXF1ZXN0MjI0OTY4MjE3","html_url":"https://github.com/friendica/friendica/pull/6003","diff_url":"https://github.com/friendica/friendica/pull/6003.diff","patch_url":"https://github.com/friendica/friendica/pull/6003.patch","issue_url":"https://api.github.com/repos/friendica/friendica/issues/6003","number":6003,"state":"open","locked":false,"title":"Fix adding / removing photo tags","user":{"login":"JonnyTischbein","id":10757520,"node_id":"MDQ6VXNlcjEwNzU3NTIw","avatar_url":"https://avatars0.githubusercontent.com/u/10757520?v=4","gravatar_id":"","url":"https://api.github.com/users/JonnyTischbein","html_url":"https://github.com/JonnyTischbein","followers_url":"https://api.github.com/users/JonnyTischbein/followers","following_url":"https://api.github.com/users/JonnyTischbein/following{/other_user}","gists_url":"https://api.github.com/users/JonnyTischbein/gists{/gist_id}","starred_url":"https://api.github.com/users/JonnyTischbein/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/JonnyTischbein/subscriptions","organizations_url":"https://api.github.com/users/JonnyTischbein/orgs","repos_url":"https://api.github.com/users/JonnyTischbein/repos","events_url":"https://api.github.com/users/JonnyTischbein/events{/privacy}","received_events_url":"https://api.github.com/users/JonnyTischbein/received_events","type":"User","site_admin":false},"body":"reopen #6002 with fixed branch\r\nTo issue #5915\r\n\r\n- changing the `Item:update` function for the field tag\r\n- adding a `Term::deleteAllTags` function\r\n- adding the possiblity to remove tag via GET `/tagrm/[id]/[hex(Tag)]`\r\n- display photo tags like categories in post with delete button\r\n![screenshot_2018-10-23_10-58-26](https://user-images.githubusercontent.com/10757520/47348865-ad035680-d6b2-11e8-8af5-62b5163e0a40.png)\r\n- fix tagrm return when no photo has no tag\r\n~~- remove `System::baseUrl()` from goaway~~","created_at":"2018-10-23T09:44:50Z","updated_at":"2018-10-23T10:58:10Z","closed_at":null,"merged_at":null,"merge_commit_sha":"957fe2d331b8d964af28d687fff610e51d05781c","assignee":null,"assignees":[],"requested_reviewers":[],"requested_teams":[],"labels":[],"milestone":null,"commits_url":"https://api.github.com/repos/friendica/friendica/pulls/6003/commits","review_comments_url":"https://api.github.com/repos/friendica/friendica/pulls/6003/comments","review_comment_url":"https://api.github.com/repos/friendica/friendica/pulls/comments{/number}","comments_url":"https://api.github.com/repos/friendica/friendica/issues/6003/comments","statuses_url":"https://api.github.com/repos/friendica/friendica/statuses/d06ddffbb7a2b772a5914e141234b180e02079b0","head":{"label":"JonnyTischbein:issue_phototag","ref":"issue_phototag","sha":"d06ddffbb7a2b772a5914e141234b180e02079b0","user":{"login":"JonnyTischbein","id":10757520,"node_id":"MDQ6VXNlcjEwNzU3NTIw","avatar_url":"https://avatars0.githubusercontent.com/u/10757520?v=4","gravatar_id":"","url":"https://api.github.com/users/JonnyTischbein","html_url":"https://github.com/JonnyTischbein","followers_url":"https://api.github.com/users/JonnyTischbein/followers","following_url":"https://api.github.com/users/JonnyTischbein/following{/other_user}","gists_url":"https://api.github.com/users/JonnyTischbein/gists{/gist_id}","starred_url":"https://api.github.com/users/JonnyTischbein/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/JonnyTischbein/subscriptions","organizations_url":"https://api.github.com/users/JonnyTischbein/orgs","repos_url":"https://api.github.com/users/JonnyTischbein/repos","events_url":"https://api.github.com/users/JonnyTischbein/events{/privacy}","received_events_url":"https://api.github.com/users/JonnyTischbein/received_events","type":"User","site_admin":false},"repo":{"id":148202444,"node_id":"MDEwOlJlcG9zaXRvcnkxNDgyMDI0NDQ=","name":"friendica","full_name":"JonnyTischbein/friendica","private":false,"owner":{"login":"JonnyTischbein","id":10757520,"node_id":"MDQ6VXNlcjEwNzU3NTIw","avatar_url":"https://avatars0.githubusercontent.com/u/10757520?v=4","gravatar_id":"","url":"https://api.github.com/users/JonnyTischbein","html_url":"https://github.com/JonnyTischbein","followers_url":"https://api.github.com/users/JonnyTischbein/followers","following_url":"https://api.github.com/users/JonnyTischbein/following{/other_user}","gists_url":"https://api.github.com/users/JonnyTischbein/gists{/gist_id}","starred_url":"https://api.github.com/users/JonnyTischbein/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/JonnyTischbein/subscriptions","organizations_url":"https://api.github.com/users/JonnyTischbein/orgs","repos_url":"https://api.github.com/users/JonnyTischbein/repos","events_url":"https://api.github.com/users/JonnyTischbein/events{/privacy}","received_events_url":"https://api.github.com/users/JonnyTischbein/received_events","type":"User","site_admin":false},"html_url":"https://github.com/JonnyTischbein/friendica","description":"Friendica Communications Platform","fork":true,"url":"https://api.github.com/repos/JonnyTischbein/friendica","forks_url":"https://api.github.com/repos/JonnyTischbein/friendica/forks","keys_url":"https://api.github.com/repos/JonnyTischbein/friendica/keys{/key_id}","collaborators_url":"https://api.github.com/repos/JonnyTischbein/friendica/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/JonnyTischbein/friendica/teams","hooks_url":"https://api.github.com/repos/JonnyTischbein/friendica/hooks","issue_events_url":"https://api.github.com/repos/JonnyTischbein/friendica/issues/events{/number}","events_url":"https://api.github.com/repos/JonnyTischbein/friendica/events","assignees_url":"https://api.github.com/repos/JonnyTischbein/friendica/assignees{/user}","branches_url":"https://api.github.com/repos/JonnyTischbein/friendica/branches{/branch}","tags_url":"https://api.github.com/repos/JonnyTischbein/friendica/tags","blobs_url":"https://api.github.com/repos/JonnyTischbein/friendica/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/JonnyTischbein/friendica/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/JonnyTischbein/friendica/git/refs{/sha}","trees_url":"https://api.github.com/repos/JonnyTischbein/friendica/git/trees{/sha}","statuses_url":"https://api.github.com/repos/JonnyTischbein/friendica/statuses/{sha}","languages_url":"https://api.github.com/repos/JonnyTischbein/friendica/languages","stargazers_url":"https://api.github.com/repos/JonnyTischbein/friendica/stargazers","contributors_url":"https://api.github.com/repos/JonnyTischbein/friendica/contributors","subscribers_url":"https://api.github.com/repos/JonnyTischbein/friendica/subscribers","subscription_url":"https://api.github.com/repos/JonnyTischbein/friendica/subscription","commits_url":"https://api.github.com/repos/JonnyTischbein/friendica/commits{/sha}","git_commits_url":"https://api.github.com/repos/JonnyTischbein/friendica/git/commits{/sha}","comments_url":"https://api.github.com/repos/JonnyTischbein/friendica/comments{/number}","issue_comment_url":"https://api.github.com/repos/JonnyTischbein/friendica/issues/comments{/number}","contents_url":"https://api.github.com/repos/JonnyTischbein/friendica/contents/{+path}","compare_url":"https://api.github.com/repos/JonnyTischbein/friendica/compare/{base}...{head}","merges_url":"https://api.github.com/repos/JonnyTischbein/friendica/merges","archive_url":"https://api.github.com/repos/JonnyTischbein/friendica/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/JonnyTischbein/friendica/downloads","issues_url":"https://api.github.com/repos/JonnyTischbein/friendica/issues{/number}","pulls_url":"https://api.github.com/repos/JonnyTischbein/friendica/pulls{/number}","milestones_url":"https://api.github.com/repos/JonnyTischbein/friendica/milestones{/number}","notifications_url":"https://api.github.com/repos/JonnyTischbein/friendica/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/JonnyTischbein/friendica/labels{/name}","releases_url":"https://api.github.com/repos/JonnyTischbein/friendica/releases{/id}","deployments_url":"https://api.github.com/repos/JonnyTischbein/friendica/deployments","created_at":"2018-09-10T18:42:07Z","updated_at":"2018-10-23T09:28:11Z","pushed_at":"2018-10-23T09:44:43Z","git_url":"git://github.com/JonnyTischbein/friendica.git","ssh_url":"git@github.com:JonnyTischbein/friendica.git","clone_url":"https://github.com/JonnyTischbein/friendica.git","svn_url":"https://github.com/JonnyTischbein/friendica","homepage":"https://friendi.ca","size":107181,"stargazers_count":1,"watchers_count":1,"language":"PHP","has_issues":false,"has_projects":true,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":0,"mirror_url":null,"archived":false,"open_issues_count":0,"license":{"key":"other","name":"Other","spdx_id":"NOASSERTION","url":null,"node_id":"MDc6TGljZW5zZTA="},"forks":0,"open_issues":0,"watchers":1,"default_branch":"develop"}},"base":{"label":"friendica:develop","ref":"develop","sha":"dbe49a0c1ad0467c2e12e363aac5635a1f11a3ea","user":{"login":"friendica","id":1176581,"node_id":"MDQ6VXNlcjExNzY1ODE=","avatar_url":"https://avatars1.githubusercontent.com/u/1176581?v=4","gravatar_id":"","url":"https://api.github.com/users/friendica","html_url":"https://github.com/friendica","followers_url":"https://api.github.com/users/friendica/followers","following_url":"https://api.github.com/users/friendica/following{/other_user}","gists_url":"https://api.github.com/users/friendica/gists{/gist_id}","starred_url":"https://api.github.com/users/friendica/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/friendica/subscriptions","organizations_url":"https://api.github.com/users/friendica/orgs","repos_url":"https://api.github.com/users/friendica/repos","events_url":"https://api.github.com/users/friendica/events{/privacy}","received_events_url":"https://api.github.com/users/friendica/received_events","type":"User","site_admin":false},"repo":{"id":2722709,"node_id":"MDEwOlJlcG9zaXRvcnkyNzIyNzA5","name":"friendica","full_name":"friendica/friendica","private":false,"owner":{"login":"friendica","id":1176581,"node_id":"MDQ6VXNlcjExNzY1ODE=","avatar_url":"https://avatars1.githubusercontent.com/u/1176581?v=4","gravatar_id":"","url":"https://api.github.com/users/friendica","html_url":"https://github.com/friendica","followers_url":"https://api.github.com/users/friendica/followers","following_url":"https://api.github.com/users/friendica/following{/other_user}","gists_url":"https://api.github.com/users/friendica/gists{/gist_id}","starred_url":"https://api.github.com/users/friendica/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/friendica/subscriptions","organizations_url":"https://api.github.com/users/friendica/orgs","repos_url":"https://api.github.com/users/friendica/repos","events_url":"https://api.github.com/users/friendica/events{/privacy}","received_events_url":"https://api.github.com/users/friendica/received_events","type":"User","site_admin":false},"html_url":"https://github.com/friendica/friendica","description":"Friendica Communications Platform","fork":true,"url":"https://api.github.com/repos/friendica/friendica","forks_url":"https://api.github.com/repos/friendica/friendica/forks","keys_url":"https://api.github.com/repos/friendica/friendica/keys{/key_id}","collaborators_url":"https://api.github.com/repos/friendica/friendica/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/friendica/friendica/teams","hooks_url":"https://api.github.com/repos/friendica/friendica/hooks","issue_events_url":"https://api.github.com/repos/friendica/friendica/issues/events{/number}","events_url":"https://api.github.com/repos/friendica/friendica/events","assignees_url":"https://api.github.com/repos/friendica/friendica/assignees{/user}","branches_url":"https://api.github.com/repos/friendica/friendica/branches{/branch}","tags_url":"https://api.github.com/repos/friendica/friendica/tags","blobs_url":"https://api.github.com/repos/friendica/friendica/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/friendica/friendica/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/friendica/friendica/git/refs{/sha}","trees_url":"https://api.github.com/repos/friendica/friendica/git/trees{/sha}","statuses_url":"https://api.github.com/repos/friendica/friendica/statuses/{sha}","languages_url":"https://api.github.com/repos/friendica/friendica/languages","stargazers_url":"https://api.github.com/repos/friendica/friendica/stargazers","contributors_url":"https://api.github.com/repos/friendica/friendica/contributors","subscribers_url":"https://api.github.com/repos/friendica/friendica/subscribers","subscription_url":"https://api.github.com/repos/friendica/friendica/subscription","commits_url":"https://api.github.com/repos/friendica/friendica/commits{/sha}","git_commits_url":"https://api.github.com/repos/friendica/friendica/git/commits{/sha}","comments_url":"https://api.github.com/repos/friendica/friendica/comments{/number}","issue_comment_url":"https://api.github.com/repos/friendica/friendica/issues/comments{/number}","contents_url":"https://api.github.com/repos/friendica/friendica/contents/{+path}","compare_url":"https://api.github.com/repos/friendica/friendica/compare/{base}...{head}","merges_url":"https://api.github.com/repos/friendica/friendica/merges","archive_url":"https://api.github.com/repos/friendica/friendica/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/friendica/friendica/downloads","issues_url":"https://api.github.com/repos/friendica/friendica/issues{/number}","pulls_url":"https://api.github.com/repos/friendica/friendica/pulls{/number}","milestones_url":"https://api.github.com/repos/friendica/friendica/milestones{/number}","notifications_url":"https://api.github.com/repos/friendica/friendica/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/friendica/friendica/labels{/name}","releases_url":"https://api.github.com/repos/friendica/friendica/releases{/id}","deployments_url":"https://api.github.com/repos/friendica/friendica/deployments","created_at":"2011-11-06T22:19:41Z","updated_at":"2018-10-23T10:26:34Z","pushed_at":"2018-10-23T10:26:29Z","git_url":"git://github.com/friendica/friendica.git","ssh_url":"git@github.com:friendica/friendica.git","clone_url":"https://github.com/friendica/friendica.git","svn_url":"https://github.com/friendica/friendica","homepage":"https://friendi.ca","size":107135,"stargazers_count":653,"watchers_count":653,"language":"PHP","has_issues":true,"has_projects":false,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":213,"mirror_url":null,"archived":false,"open_issues_count":414,"license":{"key":"other","name":"Other","spdx_id":"NOASSERTION","url":null,"node_id":"MDc6TGljZW5zZTA="},"forks":213,"open_issues":414,"watchers":653,"default_branch":"develop"}},"_links":{"self":{"href":"https://api.github.com/repos/friendica/friendica/pulls/6003"},"html":{"href":"https://github.com/friendica/friendica/pull/6003"},"issue":{"href":"https://api.github.com/repos/friendica/friendica/issues/6003"},"comments":{"href":"https://api.github.com/repos/friendica/friendica/issues/6003/comments"},"review_comments":{"href":"https://api.github.com/repos/friendica/friendica/pulls/6003/comments"},"review_comment":{"href":"https://api.github.com/repos/friendica/friendica/pulls/comments{/number}"},"commits":{"href":"https://api.github.com/repos/friendica/friendica/pulls/6003/commits"},"statuses":{"href":"https://api.github.com/repos/friendica/friendica/statuses/d06ddffbb7a2b772a5914e141234b180e02079b0"}},"author_association":"NONE"}}
{"actor":{"display_login":"annando"}}