{"action":"created","comment":{"url":"https://api.github.com/repos/FriendsOfShopware/FroshViewSnapshots/pulls/comments/215947397","pull_request_review_id":153327151,"id":215947397,"node_id":"MDI0OlB1bGxSZXF1ZXN0UmV2aWV3Q29tbWVudDIxNTk0NzM5Nw==","diff_hunk":"@@ -55,4 +58,68 @@ public function listAction()\n             ['success' => true, 'data' => $data, 'total' => $total]\n         );\n     }\n+\n+    /**\n+     * @throws ParameterMissingException\n+     * @throws Exception\n+     */\n+    public function diffAction()\n+    {\n+        $sessionFrom = $this->Request()->getParam('sessionFrom');\n+        $stepFrom = $this->Request()->getParam('stepFrom');\n+        $sessionTo = $this->Request()->getParam('sessionTo', $sessionFrom);\n+        $stepTo = $this->Request()->getParam('stepTo');\n+\n+        if (empty($sessionFrom)) {\n+            throw new ParameterMissingException('sessionFrom is missing');\n+        }\n+\n+        if (empty($stepFrom)) {\n+            throw new ParameterMissingException('stepFrom is missing');\n+        }\n+\n+        if (empty($sessionTo)) {\n+            throw new ParameterMissingException('sessionTo is missing');\n+        }\n+\n+        if (empty($stepTo)) {\n+            throw new ParameterMissingException('stepTo is missing');\n+        }\n+\n+        /** @var Diff $differ */\n+        $differ = $this->get('frosh_view_snapshots.services.diff');\n+        $dataFrom = $this->getSnapshotStep($sessionFrom, $stepFrom);\n+        $dataTo = $this->getSnapshotStep($sessionTo, $stepTo);\n+\n+        $this->View()->assign([\n+            'success' => true,\n+            'data' => [\n+                'sessionID' => $differ->diffPlain($dataFrom['sessionID'], $dataTo['sessionID'])->renderDiffToHTML(),\n+                'template' => $differ->diffPlain($dataFrom['template'], $dataTo['template'])->renderDiffToHTML(),\n+                'step' => $differ->diffPlain($dataFrom['step'], $dataTo['step'])->renderDiffToHTML(),\n+                'variables' => $differ->diffSerialized($dataFrom['variables'], $dataTo['variables'])->renderDiffToHTML(),\n+                'params' => $differ->diffJson($dataFrom['params'], $dataTo['params'])->renderDiffToHTML(),\n+            ],\n+        ]);\n+    }\n+\n+    /**\n+     * @throws Exception","path":"Controllers/Backend/ViewSnapshots.php","position":59,"original_position":59,"commit_id":"cae0722ce8caef4aea0d984f0445814520e0e602","original_commit_id":"cae0722ce8caef4aea0d984f0445814520e0e602","user":{"login":"kleinmann","id":85701,"node_id":"MDQ6VXNlcjg1NzAx","avatar_url":"https://avatars0.githubusercontent.com/u/85701?v=4","gravatar_id":"","url":"https://api.github.com/users/kleinmann","html_url":"https://github.com/kleinmann","followers_url":"https://api.github.com/users/kleinmann/followers","following_url":"https://api.github.com/users/kleinmann/following{/other_user}","gists_url":"https://api.github.com/users/kleinmann/gists{/gist_id}","starred_url":"https://api.github.com/users/kleinmann/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/kleinmann/subscriptions","organizations_url":"https://api.github.com/users/kleinmann/orgs","repos_url":"https://api.github.com/users/kleinmann/repos","events_url":"https://api.github.com/users/kleinmann/events{/privacy}","received_events_url":"https://api.github.com/users/kleinmann/received_events","type":"User","site_admin":false},"body":"We're  only adding type hints as PHPDoc if they add more value, e.g. `int[]` instead of only `array` in the signature. If the information is redundant, I support not having it in the PHPDoc.","created_at":"2018-09-07T12:49:25Z","updated_at":"2018-09-07T12:49:25Z","html_url":"https://github.com/FriendsOfShopware/FroshViewSnapshots/pull/5#discussion_r215947397","pull_request_url":"https://api.github.com/repos/FriendsOfShopware/FroshViewSnapshots/pulls/5","author_association":"MEMBER","_links":{"self":{"href":"https://api.github.com/repos/FriendsOfShopware/FroshViewSnapshots/pulls/comments/215947397"},"html":{"href":"https://github.com/FriendsOfShopware/FroshViewSnapshots/pull/5#discussion_r215947397"},"pull_request":{"href":"https://api.github.com/repos/FriendsOfShopware/FroshViewSnapshots/pulls/5"}},"in_reply_to_id":215860881},"pull_request":{"url":"https://api.github.com/repos/FriendsOfShopware/FroshViewSnapshots/pulls/5","id":213759620,"node_id":"MDExOlB1bGxSZXF1ZXN0MjEzNzU5NjIw","html_url":"https://github.com/FriendsOfShopware/FroshViewSnapshots/pull/5","diff_url":"https://github.com/FriendsOfShopware/FroshViewSnapshots/pull/5.diff","patch_url":"https://github.com/FriendsOfShopware/FroshViewSnapshots/pull/5.patch","issue_url":"https://api.github.com/repos/FriendsOfShopware/FroshViewSnapshots/issues/5","number":5,"state":"open","locked":false,"title":"Added diff service to compare two steps in any session","user":{"login":"JoshuaBehrens","id":1133593,"node_id":"MDQ6VXNlcjExMzM1OTM=","avatar_url":"https://avatars0.githubusercontent.com/u/1133593?v=4","gravatar_id":"","url":"https://api.github.com/users/JoshuaBehrens","html_url":"https://github.com/JoshuaBehrens","followers_url":"https://api.github.com/users/JoshuaBehrens/followers","following_url":"https://api.github.com/users/JoshuaBehrens/following{/other_user}","gists_url":"https://api.github.com/users/JoshuaBehrens/gists{/gist_id}","starred_url":"https://api.github.com/users/JoshuaBehrens/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/JoshuaBehrens/subscriptions","organizations_url":"https://api.github.com/users/JoshuaBehrens/orgs","repos_url":"https://api.github.com/users/JoshuaBehrens/repos","events_url":"https://api.github.com/users/JoshuaBehrens/events{/privacy}","received_events_url":"https://api.github.com/users/JoshuaBehrens/received_events","type":"User","site_admin":false},"body":"I added a diff service and a backend action to compare two steps in any given session. A backend view and action buttons are missing.\r\nIt would be :cool: when someone else can add these to the backend application.\r\n\r\n","created_at":"2018-09-06T21:45:29Z","updated_at":"2018-09-07T12:49:25Z","closed_at":null,"merged_at":null,"merge_commit_sha":"369af6da3bb10b8714e346edf0212e8f453aadad","assignee":null,"assignees":[],"requested_reviewers":[],"requested_teams":[],"labels":[{"id":907510487,"node_id":"MDU6TGFiZWw5MDc1MTA0ODc=","url":"https://api.github.com/repos/FriendsOfShopware/FroshViewSnapshots/labels/enhancement","name":"enhancement","color":"a2eeef","default":true},{"id":907510488,"node_id":"MDU6TGFiZWw5MDc1MTA0ODg=","url":"https://api.github.com/repos/FriendsOfShopware/FroshViewSnapshots/labels/help%20wanted","name":"help wanted","color":"008672","default":true}],"milestone":null,"commits_url":"https://api.github.com/repos/FriendsOfShopware/FroshViewSnapshots/pulls/5/commits","review_comments_url":"https://api.github.com/repos/FriendsOfShopware/FroshViewSnapshots/pulls/5/comments","review_comment_url":"https://api.github.com/repos/FriendsOfShopware/FroshViewSnapshots/pulls/comments{/number}","comments_url":"https://api.github.com/repos/FriendsOfShopware/FroshViewSnapshots/issues/5/comments","statuses_url":"https://api.github.com/repos/FriendsOfShopware/FroshViewSnapshots/statuses/cae0722ce8caef4aea0d984f0445814520e0e602","head":{"label":"niemand-online:no/diff-view","ref":"no/diff-view","sha":"cae0722ce8caef4aea0d984f0445814520e0e602","user":{"login":"niemand-online","id":32938202,"node_id":"MDEyOk9yZ2FuaXphdGlvbjMyOTM4MjAy","avatar_url":"https://avatars2.githubusercontent.com/u/32938202?v=4","gravatar_id":"","url":"https://api.github.com/users/niemand-online","html_url":"https://github.com/niemand-online","followers_url":"https://api.github.com/users/niemand-online/followers","following_url":"https://api.github.com/users/niemand-online/following{/other_user}","gists_url":"https://api.github.com/users/niemand-online/gists{/gist_id}","starred_url":"https://api.github.com/users/niemand-online/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/niemand-online/subscriptions","organizations_url":"https://api.github.com/users/niemand-online/orgs","repos_url":"https://api.github.com/users/niemand-online/repos","events_url":"https://api.github.com/users/niemand-online/events{/privacy}","received_events_url":"https://api.github.com/users/niemand-online/received_events","type":"Organization","site_admin":false},"repo":{"id":147722161,"node_id":"MDEwOlJlcG9zaXRvcnkxNDc3MjIxNjE=","name":"FroshViewSnapshots","full_name":"niemand-online/FroshViewSnapshots","owner":{"login":"niemand-online","id":32938202,"node_id":"MDEyOk9yZ2FuaXphdGlvbjMyOTM4MjAy","avatar_url":"https://avatars2.githubusercontent.com/u/32938202?v=4","gravatar_id":"","url":"https://api.github.com/users/niemand-online","html_url":"https://github.com/niemand-online","followers_url":"https://api.github.com/users/niemand-online/followers","following_url":"https://api.github.com/users/niemand-online/following{/other_user}","gists_url":"https://api.github.com/users/niemand-online/gists{/gist_id}","starred_url":"https://api.github.com/users/niemand-online/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/niemand-online/subscriptions","organizations_url":"https://api.github.com/users/niemand-online/orgs","repos_url":"https://api.github.com/users/niemand-online/repos","events_url":"https://api.github.com/users/niemand-online/events{/privacy}","received_events_url":"https://api.github.com/users/niemand-online/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/niemand-online/FroshViewSnapshots","description":"Shopware plugin that allows you to record/log views and restore them","fork":true,"url":"https://api.github.com/repos/niemand-online/FroshViewSnapshots","forks_url":"https://api.github.com/repos/niemand-online/FroshViewSnapshots/forks","keys_url":"https://api.github.com/repos/niemand-online/FroshViewSnapshots/keys{/key_id}","collaborators_url":"https://api.github.com/repos/niemand-online/FroshViewSnapshots/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/niemand-online/FroshViewSnapshots/teams","hooks_url":"https://api.github.com/repos/niemand-online/FroshViewSnapshots/hooks","issue_events_url":"https://api.github.com/repos/niemand-online/FroshViewSnapshots/issues/events{/number}","events_url":"https://api.github.com/repos/niemand-online/FroshViewSnapshots/events","assignees_url":"https://api.github.com/repos/niemand-online/FroshViewSnapshots/assignees{/user}","branches_url":"https://api.github.com/repos/niemand-online/FroshViewSnapshots/branches{/branch}","tags_url":"https://api.github.com/repos/niemand-online/FroshViewSnapshots/tags","blobs_url":"https://api.github.com/repos/niemand-online/FroshViewSnapshots/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/niemand-online/FroshViewSnapshots/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/niemand-online/FroshViewSnapshots/git/refs{/sha}","trees_url":"https://api.github.com/repos/niemand-online/FroshViewSnapshots/git/trees{/sha}","statuses_url":"https://api.github.com/repos/niemand-online/FroshViewSnapshots/statuses/{sha}","languages_url":"https://api.github.com/repos/niemand-online/FroshViewSnapshots/languages","stargazers_url":"https://api.github.com/repos/niemand-online/FroshViewSnapshots/stargazers","contributors_url":"https://api.github.com/repos/niemand-online/FroshViewSnapshots/contributors","subscribers_url":"https://api.github.com/repos/niemand-online/FroshViewSnapshots/subscribers","subscription_url":"https://api.github.com/repos/niemand-online/FroshViewSnapshots/subscription","commits_url":"https://api.github.com/repos/niemand-online/FroshViewSnapshots/commits{/sha}","git_commits_url":"https://api.github.com/repos/niemand-online/FroshViewSnapshots/git/commits{/sha}","comments_url":"https://api.github.com/repos/niemand-online/FroshViewSnapshots/comments{/number}","issue_comment_url":"https://api.github.com/repos/niemand-online/FroshViewSnapshots/issues/comments{/number}","contents_url":"https://api.github.com/repos/niemand-online/FroshViewSnapshots/contents/{+path}","compare_url":"https://api.github.com/repos/niemand-online/FroshViewSnapshots/compare/{base}...{head}","merges_url":"https://api.github.com/repos/niemand-online/FroshViewSnapshots/merges","archive_url":"https://api.github.com/repos/niemand-online/FroshViewSnapshots/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/niemand-online/FroshViewSnapshots/downloads","issues_url":"https://api.github.com/repos/niemand-online/FroshViewSnapshots/issues{/number}","pulls_url":"https://api.github.com/repos/niemand-online/FroshViewSnapshots/pulls{/number}","milestones_url":"https://api.github.com/repos/niemand-online/FroshViewSnapshots/milestones{/number}","notifications_url":"https://api.github.com/repos/niemand-online/FroshViewSnapshots/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/niemand-online/FroshViewSnapshots/labels{/name}","releases_url":"https://api.github.com/repos/niemand-online/FroshViewSnapshots/releases{/id}","deployments_url":"https://api.github.com/repos/niemand-online/FroshViewSnapshots/deployments","created_at":"2018-09-06T19:19:21Z","updated_at":"2018-09-06T19:19:23Z","pushed_at":"2018-09-06T21:39:36Z","git_url":"git://github.com/niemand-online/FroshViewSnapshots.git","ssh_url":"git@github.com:niemand-online/FroshViewSnapshots.git","clone_url":"https://github.com/niemand-online/FroshViewSnapshots.git","svn_url":"https://github.com/niemand-online/FroshViewSnapshots","homepage":"","size":29,"stargazers_count":0,"watchers_count":0,"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":"mit","name":"MIT License","spdx_id":"MIT","url":"https://api.github.com/licenses/mit","node_id":"MDc6TGljZW5zZTEz"},"forks":0,"open_issues":0,"watchers":0,"default_branch":"master"}},"base":{"label":"FriendsOfShopware:master","ref":"master","sha":"87fe107da84794a5dc87256090ee0e768f0bb7df","user":{"login":"FriendsOfShopware","id":36633261,"node_id":"MDEyOk9yZ2FuaXphdGlvbjM2NjMzMjYx","avatar_url":"https://avatars2.githubusercontent.com/u/36633261?v=4","gravatar_id":"","url":"https://api.github.com/users/FriendsOfShopware","html_url":"https://github.com/FriendsOfShopware","followers_url":"https://api.github.com/users/FriendsOfShopware/followers","following_url":"https://api.github.com/users/FriendsOfShopware/following{/other_user}","gists_url":"https://api.github.com/users/FriendsOfShopware/gists{/gist_id}","starred_url":"https://api.github.com/users/FriendsOfShopware/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/FriendsOfShopware/subscriptions","organizations_url":"https://api.github.com/users/FriendsOfShopware/orgs","repos_url":"https://api.github.com/users/FriendsOfShopware/repos","events_url":"https://api.github.com/users/FriendsOfShopware/events{/privacy}","received_events_url":"https://api.github.com/users/FriendsOfShopware/received_events","type":"Organization","site_admin":false},"repo":{"id":130248080,"node_id":"MDEwOlJlcG9zaXRvcnkxMzAyNDgwODA=","name":"FroshViewSnapshots","full_name":"FriendsOfShopware/FroshViewSnapshots","owner":{"login":"FriendsOfShopware","id":36633261,"node_id":"MDEyOk9yZ2FuaXphdGlvbjM2NjMzMjYx","avatar_url":"https://avatars2.githubusercontent.com/u/36633261?v=4","gravatar_id":"","url":"https://api.github.com/users/FriendsOfShopware","html_url":"https://github.com/FriendsOfShopware","followers_url":"https://api.github.com/users/FriendsOfShopware/followers","following_url":"https://api.github.com/users/FriendsOfShopware/following{/other_user}","gists_url":"https://api.github.com/users/FriendsOfShopware/gists{/gist_id}","starred_url":"https://api.github.com/users/FriendsOfShopware/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/FriendsOfShopware/subscriptions","organizations_url":"https://api.github.com/users/FriendsOfShopware/orgs","repos_url":"https://api.github.com/users/FriendsOfShopware/repos","events_url":"https://api.github.com/users/FriendsOfShopware/events{/privacy}","received_events_url":"https://api.github.com/users/FriendsOfShopware/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/FriendsOfShopware/FroshViewSnapshots","description":"Shopware plugin that allows you to record/log views and restore them","fork":false,"url":"https://api.github.com/repos/FriendsOfShopware/FroshViewSnapshots","forks_url":"https://api.github.com/repos/FriendsOfShopware/FroshViewSnapshots/forks","keys_url":"https://api.github.com/repos/FriendsOfShopware/FroshViewSnapshots/keys{/key_id}","collaborators_url":"https://api.github.com/repos/FriendsOfShopware/FroshViewSnapshots/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/FriendsOfShopware/FroshViewSnapshots/teams","hooks_url":"https://api.github.com/repos/FriendsOfShopware/FroshViewSnapshots/hooks","issue_events_url":"https://api.github.com/repos/FriendsOfShopware/FroshViewSnapshots/issues/events{/number}","events_url":"https://api.github.com/repos/FriendsOfShopware/FroshViewSnapshots/events","assignees_url":"https://api.github.com/repos/FriendsOfShopware/FroshViewSnapshots/assignees{/user}","branches_url":"https://api.github.com/repos/FriendsOfShopware/FroshViewSnapshots/branches{/branch}","tags_url":"https://api.github.com/repos/FriendsOfShopware/FroshViewSnapshots/tags","blobs_url":"https://api.github.com/repos/FriendsOfShopware/FroshViewSnapshots/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/FriendsOfShopware/FroshViewSnapshots/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/FriendsOfShopware/FroshViewSnapshots/git/refs{/sha}","trees_url":"https://api.github.com/repos/FriendsOfShopware/FroshViewSnapshots/git/trees{/sha}","statuses_url":"https://api.github.com/repos/FriendsOfShopware/FroshViewSnapshots/statuses/{sha}","languages_url":"https://api.github.com/repos/FriendsOfShopware/FroshViewSnapshots/languages","stargazers_url":"https://api.github.com/repos/FriendsOfShopware/FroshViewSnapshots/stargazers","contributors_url":"https://api.github.com/repos/FriendsOfShopware/FroshViewSnapshots/contributors","subscribers_url":"https://api.github.com/repos/FriendsOfShopware/FroshViewSnapshots/subscribers","subscription_url":"https://api.github.com/repos/FriendsOfShopware/FroshViewSnapshots/subscription","commits_url":"https://api.github.com/repos/FriendsOfShopware/FroshViewSnapshots/commits{/sha}","git_commits_url":"https://api.github.com/repos/FriendsOfShopware/FroshViewSnapshots/git/commits{/sha}","comments_url":"https://api.github.com/repos/FriendsOfShopware/FroshViewSnapshots/comments{/number}","issue_comment_url":"https://api.github.com/repos/FriendsOfShopware/FroshViewSnapshots/issues/comments{/number}","contents_url":"https://api.github.com/repos/FriendsOfShopware/FroshViewSnapshots/contents/{+path}","compare_url":"https://api.github.com/repos/FriendsOfShopware/FroshViewSnapshots/compare/{base}...{head}","merges_url":"https://api.github.com/repos/FriendsOfShopware/FroshViewSnapshots/merges","archive_url":"https://api.github.com/repos/FriendsOfShopware/FroshViewSnapshots/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/FriendsOfShopware/FroshViewSnapshots/downloads","issues_url":"https://api.github.com/repos/FriendsOfShopware/FroshViewSnapshots/issues{/number}","pulls_url":"https://api.github.com/repos/FriendsOfShopware/FroshViewSnapshots/pulls{/number}","milestones_url":"https://api.github.com/repos/FriendsOfShopware/FroshViewSnapshots/milestones{/number}","notifications_url":"https://api.github.com/repos/FriendsOfShopware/FroshViewSnapshots/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/FriendsOfShopware/FroshViewSnapshots/labels{/name}","releases_url":"https://api.github.com/repos/FriendsOfShopware/FroshViewSnapshots/releases{/id}","deployments_url":"https://api.github.com/repos/FriendsOfShopware/FroshViewSnapshots/deployments","created_at":"2018-04-19T17:10:48Z","updated_at":"2018-09-06T21:55:29Z","pushed_at":"2018-09-06T21:45:31Z","git_url":"git://github.com/FriendsOfShopware/FroshViewSnapshots.git","ssh_url":"git@github.com:FriendsOfShopware/FroshViewSnapshots.git","clone_url":"https://github.com/FriendsOfShopware/FroshViewSnapshots.git","svn_url":"https://github.com/FriendsOfShopware/FroshViewSnapshots","homepage":"","size":25,"stargazers_count":0,"watchers_count":0,"language":"PHP","has_issues":true,"has_projects":true,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":2,"mirror_url":null,"archived":false,"open_issues_count":5,"license":{"key":"mit","name":"MIT License","spdx_id":"MIT","url":"https://api.github.com/licenses/mit","node_id":"MDc6TGljZW5zZTEz"},"forks":2,"open_issues":5,"watchers":0,"default_branch":"master"}},"_links":{"self":{"href":"https://api.github.com/repos/FriendsOfShopware/FroshViewSnapshots/pulls/5"},"html":{"href":"https://github.com/FriendsOfShopware/FroshViewSnapshots/pull/5"},"issue":{"href":"https://api.github.com/repos/FriendsOfShopware/FroshViewSnapshots/issues/5"},"comments":{"href":"https://api.github.com/repos/FriendsOfShopware/FroshViewSnapshots/issues/5/comments"},"review_comments":{"href":"https://api.github.com/repos/FriendsOfShopware/FroshViewSnapshots/pulls/5/comments"},"review_comment":{"href":"https://api.github.com/repos/FriendsOfShopware/FroshViewSnapshots/pulls/comments{/number}"},"commits":{"href":"https://api.github.com/repos/FriendsOfShopware/FroshViewSnapshots/pulls/5/commits"},"statuses":{"href":"https://api.github.com/repos/FriendsOfShopware/FroshViewSnapshots/statuses/cae0722ce8caef4aea0d984f0445814520e0e602"}},"author_association":"NONE"}}
{"actor":{"display_login":"kleinmann"}}