{"action":"created","comment":{"url":"https://api.github.com/repos/XHawk87/CreateYourOwnMenus/pulls/comments/226079724","pull_request_review_id":165817703,"id":226079724,"node_id":"MDI0OlB1bGxSZXF1ZXN0UmV2aWV3Q29tbWVudDIyNjA3OTcyNA==","diff_hunk":"@@ -253,6 +307,101 @@ private void onReload(FileConfiguration data) {\n         }\n     }\n \n+    /**\n+     * Checks if there is a placeholder in the string\n+     */\n+    private void hasItemPlaceholders(int slot, ItemStack item){\n+        //check if placeholders are enabled!\n+        if (!Bukkit.getPluginManager().isPluginEnabled(\"PlaceholderAPI\"))\n+            return;\n+\n+\n+        Placeholder placeholder = new Placeholder(slot, item);\n+        boolean retVal = false;\n+\n+        //check if title has an placeholder in it\n+        if(PlaceholderAPI.containsPlaceholders(item.getItemMeta().getDisplayName())) {\n+            placeholder.title = item.getItemMeta().getDisplayName();\n+            retVal = true;\n+        }\n+\n+        //check if placeholders can be found in a lore\n+        int index = 0;\n+        if(item.getItemMeta().getLore() != null)\n+            for(String s : item.getItemMeta().getLore()){\n+                if(PlaceholderAPI.containsPlaceholders(s)){\n+                    placeholder.lorePlaceholderPositions.put(index,s);\n+                    retVal = true;\n+\n+                }\n+                index++;\n+            }\n+\n+        //if we have found a placeholder lets add it\n+        if(retVal){\n+            placeholderList.add(placeholder);\n+        }\n+\n+    }\n+\n+    /**\n+     * Placeholder Data and simple inner class\n+     */\n+\n+\n+    private List<Placeholder> placeholderList = new ArrayList<Placeholder>();\n+\n+    private class Placeholder{\n+        private Placeholder( int slot, ItemStack item){\n+            this.slot = slot;\n+            this.item = item;\n+        }\n+        private ItemStack item; //backing up the item\n+        private int slot;\n+        private String title;\n+        private Map<Integer,String> lorePlaceholderPositions = new TreeMap<>();\n+        //private List<Integer> lorePlaceholderPositions = new ArrayList<>();\n+\n+","path":"src/main/java/me/xhawk87/CreateYourOwnMenus/Menu.java","position":208,"original_position":208,"commit_id":"bcd32131caaf2e1ab176067bcdc4adf489416166","original_commit_id":"bcd32131caaf2e1ab176067bcdc4adf489416166","user":{"login":"Peda1996","id":1789749,"node_id":"MDQ6VXNlcjE3ODk3NDk=","avatar_url":"https://avatars0.githubusercontent.com/u/1789749?v=4","gravatar_id":"","url":"https://api.github.com/users/Peda1996","html_url":"https://github.com/Peda1996","followers_url":"https://api.github.com/users/Peda1996/followers","following_url":"https://api.github.com/users/Peda1996/following{/other_user}","gists_url":"https://api.github.com/users/Peda1996/gists{/gist_id}","starred_url":"https://api.github.com/users/Peda1996/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/Peda1996/subscriptions","organizations_url":"https://api.github.com/users/Peda1996/orgs","repos_url":"https://api.github.com/users/Peda1996/repos","events_url":"https://api.github.com/users/Peda1996/events{/privacy}","received_events_url":"https://api.github.com/users/Peda1996/received_events","type":"User","site_admin":false},"body":"Well..","created_at":"2018-10-17T20:17:59Z","updated_at":"2018-10-17T20:17:59Z","html_url":"https://github.com/XHawk87/CreateYourOwnMenus/pull/20#discussion_r226079724","pull_request_url":"https://api.github.com/repos/XHawk87/CreateYourOwnMenus/pulls/20","author_association":"NONE","_links":{"self":{"href":"https://api.github.com/repos/XHawk87/CreateYourOwnMenus/pulls/comments/226079724"},"html":{"href":"https://github.com/XHawk87/CreateYourOwnMenus/pull/20#discussion_r226079724"},"pull_request":{"href":"https://api.github.com/repos/XHawk87/CreateYourOwnMenus/pulls/20"}},"in_reply_to_id":226016566},"pull_request":{"url":"https://api.github.com/repos/XHawk87/CreateYourOwnMenus/pulls/20","id":210977201,"node_id":"MDExOlB1bGxSZXF1ZXN0MjEwOTc3MjAx","html_url":"https://github.com/XHawk87/CreateYourOwnMenus/pull/20","diff_url":"https://github.com/XHawk87/CreateYourOwnMenus/pull/20.diff","patch_url":"https://github.com/XHawk87/CreateYourOwnMenus/pull/20.patch","issue_url":"https://api.github.com/repos/XHawk87/CreateYourOwnMenus/issues/20","number":20,"state":"open","locked":false,"title":"Quick and dirty fixes for the new 1.12 Problems!","user":{"login":"Peda1996","id":1789749,"node_id":"MDQ6VXNlcjE3ODk3NDk=","avatar_url":"https://avatars0.githubusercontent.com/u/1789749?v=4","gravatar_id":"","url":"https://api.github.com/users/Peda1996","html_url":"https://github.com/Peda1996","followers_url":"https://api.github.com/users/Peda1996/followers","following_url":"https://api.github.com/users/Peda1996/following{/other_user}","gists_url":"https://api.github.com/users/Peda1996/gists{/gist_id}","starred_url":"https://api.github.com/users/Peda1996/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/Peda1996/subscriptions","organizations_url":"https://api.github.com/users/Peda1996/orgs","repos_url":"https://api.github.com/users/Peda1996/repos","events_url":"https://api.github.com/users/Peda1996/events{/privacy}","received_events_url":"https://api.github.com/users/Peda1996/received_events","type":"User","site_admin":false},"body":"Just fixed the pom.xml, removed items which where causing problems in the console and added something in the config where you can toggle, to avoid the security flaws.:\r\nonly-playercommands: false","created_at":"2018-08-26T23:30:12Z","updated_at":"2018-10-17T20:17:59Z","closed_at":null,"merged_at":null,"merge_commit_sha":"d51262d7511561e63fb2a2acdd43b5052bbed32f","assignee":null,"assignees":[],"requested_reviewers":[],"requested_teams":[],"labels":[],"milestone":null,"commits_url":"https://api.github.com/repos/XHawk87/CreateYourOwnMenus/pulls/20/commits","review_comments_url":"https://api.github.com/repos/XHawk87/CreateYourOwnMenus/pulls/20/comments","review_comment_url":"https://api.github.com/repos/XHawk87/CreateYourOwnMenus/pulls/comments{/number}","comments_url":"https://api.github.com/repos/XHawk87/CreateYourOwnMenus/issues/20/comments","statuses_url":"https://api.github.com/repos/XHawk87/CreateYourOwnMenus/statuses/bcd32131caaf2e1ab176067bcdc4adf489416166","head":{"label":"Peda1996:master","ref":"master","sha":"bcd32131caaf2e1ab176067bcdc4adf489416166","user":{"login":"Peda1996","id":1789749,"node_id":"MDQ6VXNlcjE3ODk3NDk=","avatar_url":"https://avatars0.githubusercontent.com/u/1789749?v=4","gravatar_id":"","url":"https://api.github.com/users/Peda1996","html_url":"https://github.com/Peda1996","followers_url":"https://api.github.com/users/Peda1996/followers","following_url":"https://api.github.com/users/Peda1996/following{/other_user}","gists_url":"https://api.github.com/users/Peda1996/gists{/gist_id}","starred_url":"https://api.github.com/users/Peda1996/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/Peda1996/subscriptions","organizations_url":"https://api.github.com/users/Peda1996/orgs","repos_url":"https://api.github.com/users/Peda1996/repos","events_url":"https://api.github.com/users/Peda1996/events{/privacy}","received_events_url":"https://api.github.com/users/Peda1996/received_events","type":"User","site_admin":false},"repo":{"id":146224139,"node_id":"MDEwOlJlcG9zaXRvcnkxNDYyMjQxMzk=","name":"CreateYourOwnMenus","full_name":"Peda1996/CreateYourOwnMenus","private":false,"owner":{"login":"Peda1996","id":1789749,"node_id":"MDQ6VXNlcjE3ODk3NDk=","avatar_url":"https://avatars0.githubusercontent.com/u/1789749?v=4","gravatar_id":"","url":"https://api.github.com/users/Peda1996","html_url":"https://github.com/Peda1996","followers_url":"https://api.github.com/users/Peda1996/followers","following_url":"https://api.github.com/users/Peda1996/following{/other_user}","gists_url":"https://api.github.com/users/Peda1996/gists{/gist_id}","starred_url":"https://api.github.com/users/Peda1996/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/Peda1996/subscriptions","organizations_url":"https://api.github.com/users/Peda1996/orgs","repos_url":"https://api.github.com/users/Peda1996/repos","events_url":"https://api.github.com/users/Peda1996/events{/privacy}","received_events_url":"https://api.github.com/users/Peda1996/received_events","type":"User","site_admin":false},"html_url":"https://github.com/Peda1996/CreateYourOwnMenus","description":"A Bukkit plugin to allow server owners to design and create their own menus in-game","fork":true,"url":"https://api.github.com/repos/Peda1996/CreateYourOwnMenus","forks_url":"https://api.github.com/repos/Peda1996/CreateYourOwnMenus/forks","keys_url":"https://api.github.com/repos/Peda1996/CreateYourOwnMenus/keys{/key_id}","collaborators_url":"https://api.github.com/repos/Peda1996/CreateYourOwnMenus/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/Peda1996/CreateYourOwnMenus/teams","hooks_url":"https://api.github.com/repos/Peda1996/CreateYourOwnMenus/hooks","issue_events_url":"https://api.github.com/repos/Peda1996/CreateYourOwnMenus/issues/events{/number}","events_url":"https://api.github.com/repos/Peda1996/CreateYourOwnMenus/events","assignees_url":"https://api.github.com/repos/Peda1996/CreateYourOwnMenus/assignees{/user}","branches_url":"https://api.github.com/repos/Peda1996/CreateYourOwnMenus/branches{/branch}","tags_url":"https://api.github.com/repos/Peda1996/CreateYourOwnMenus/tags","blobs_url":"https://api.github.com/repos/Peda1996/CreateYourOwnMenus/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/Peda1996/CreateYourOwnMenus/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/Peda1996/CreateYourOwnMenus/git/refs{/sha}","trees_url":"https://api.github.com/repos/Peda1996/CreateYourOwnMenus/git/trees{/sha}","statuses_url":"https://api.github.com/repos/Peda1996/CreateYourOwnMenus/statuses/{sha}","languages_url":"https://api.github.com/repos/Peda1996/CreateYourOwnMenus/languages","stargazers_url":"https://api.github.com/repos/Peda1996/CreateYourOwnMenus/stargazers","contributors_url":"https://api.github.com/repos/Peda1996/CreateYourOwnMenus/contributors","subscribers_url":"https://api.github.com/repos/Peda1996/CreateYourOwnMenus/subscribers","subscription_url":"https://api.github.com/repos/Peda1996/CreateYourOwnMenus/subscription","commits_url":"https://api.github.com/repos/Peda1996/CreateYourOwnMenus/commits{/sha}","git_commits_url":"https://api.github.com/repos/Peda1996/CreateYourOwnMenus/git/commits{/sha}","comments_url":"https://api.github.com/repos/Peda1996/CreateYourOwnMenus/comments{/number}","issue_comment_url":"https://api.github.com/repos/Peda1996/CreateYourOwnMenus/issues/comments{/number}","contents_url":"https://api.github.com/repos/Peda1996/CreateYourOwnMenus/contents/{+path}","compare_url":"https://api.github.com/repos/Peda1996/CreateYourOwnMenus/compare/{base}...{head}","merges_url":"https://api.github.com/repos/Peda1996/CreateYourOwnMenus/merges","archive_url":"https://api.github.com/repos/Peda1996/CreateYourOwnMenus/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/Peda1996/CreateYourOwnMenus/downloads","issues_url":"https://api.github.com/repos/Peda1996/CreateYourOwnMenus/issues{/number}","pulls_url":"https://api.github.com/repos/Peda1996/CreateYourOwnMenus/pulls{/number}","milestones_url":"https://api.github.com/repos/Peda1996/CreateYourOwnMenus/milestones{/number}","notifications_url":"https://api.github.com/repos/Peda1996/CreateYourOwnMenus/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/Peda1996/CreateYourOwnMenus/labels{/name}","releases_url":"https://api.github.com/repos/Peda1996/CreateYourOwnMenus/releases{/id}","deployments_url":"https://api.github.com/repos/Peda1996/CreateYourOwnMenus/deployments","created_at":"2018-08-26T23:27:05Z","updated_at":"2018-10-17T11:27:27Z","pushed_at":"2018-10-17T11:27:26Z","git_url":"git://github.com/Peda1996/CreateYourOwnMenus.git","ssh_url":"git@github.com:Peda1996/CreateYourOwnMenus.git","clone_url":"https://github.com/Peda1996/CreateYourOwnMenus.git","svn_url":"https://github.com/Peda1996/CreateYourOwnMenus","homepage":null,"size":242,"stargazers_count":0,"watchers_count":0,"language":"Java","has_issues":false,"has_projects":true,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":1,"mirror_url":null,"archived":false,"open_issues_count":0,"license":null,"forks":1,"open_issues":0,"watchers":0,"default_branch":"master"}},"base":{"label":"XHawk87:master","ref":"master","sha":"d4862e8a83476d1fd5b2a0471dd443a48fb467f5","user":{"login":"XHawk87","id":3580617,"node_id":"MDQ6VXNlcjM1ODA2MTc=","avatar_url":"https://avatars1.githubusercontent.com/u/3580617?v=4","gravatar_id":"","url":"https://api.github.com/users/XHawk87","html_url":"https://github.com/XHawk87","followers_url":"https://api.github.com/users/XHawk87/followers","following_url":"https://api.github.com/users/XHawk87/following{/other_user}","gists_url":"https://api.github.com/users/XHawk87/gists{/gist_id}","starred_url":"https://api.github.com/users/XHawk87/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/XHawk87/subscriptions","organizations_url":"https://api.github.com/users/XHawk87/orgs","repos_url":"https://api.github.com/users/XHawk87/repos","events_url":"https://api.github.com/users/XHawk87/events{/privacy}","received_events_url":"https://api.github.com/users/XHawk87/received_events","type":"User","site_admin":false},"repo":{"id":10767012,"node_id":"MDEwOlJlcG9zaXRvcnkxMDc2NzAxMg==","name":"CreateYourOwnMenus","full_name":"XHawk87/CreateYourOwnMenus","private":false,"owner":{"login":"XHawk87","id":3580617,"node_id":"MDQ6VXNlcjM1ODA2MTc=","avatar_url":"https://avatars1.githubusercontent.com/u/3580617?v=4","gravatar_id":"","url":"https://api.github.com/users/XHawk87","html_url":"https://github.com/XHawk87","followers_url":"https://api.github.com/users/XHawk87/followers","following_url":"https://api.github.com/users/XHawk87/following{/other_user}","gists_url":"https://api.github.com/users/XHawk87/gists{/gist_id}","starred_url":"https://api.github.com/users/XHawk87/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/XHawk87/subscriptions","organizations_url":"https://api.github.com/users/XHawk87/orgs","repos_url":"https://api.github.com/users/XHawk87/repos","events_url":"https://api.github.com/users/XHawk87/events{/privacy}","received_events_url":"https://api.github.com/users/XHawk87/received_events","type":"User","site_admin":false},"html_url":"https://github.com/XHawk87/CreateYourOwnMenus","description":"A Bukkit plugin to allow server owners to design and create their own menus in-game","fork":false,"url":"https://api.github.com/repos/XHawk87/CreateYourOwnMenus","forks_url":"https://api.github.com/repos/XHawk87/CreateYourOwnMenus/forks","keys_url":"https://api.github.com/repos/XHawk87/CreateYourOwnMenus/keys{/key_id}","collaborators_url":"https://api.github.com/repos/XHawk87/CreateYourOwnMenus/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/XHawk87/CreateYourOwnMenus/teams","hooks_url":"https://api.github.com/repos/XHawk87/CreateYourOwnMenus/hooks","issue_events_url":"https://api.github.com/repos/XHawk87/CreateYourOwnMenus/issues/events{/number}","events_url":"https://api.github.com/repos/XHawk87/CreateYourOwnMenus/events","assignees_url":"https://api.github.com/repos/XHawk87/CreateYourOwnMenus/assignees{/user}","branches_url":"https://api.github.com/repos/XHawk87/CreateYourOwnMenus/branches{/branch}","tags_url":"https://api.github.com/repos/XHawk87/CreateYourOwnMenus/tags","blobs_url":"https://api.github.com/repos/XHawk87/CreateYourOwnMenus/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/XHawk87/CreateYourOwnMenus/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/XHawk87/CreateYourOwnMenus/git/refs{/sha}","trees_url":"https://api.github.com/repos/XHawk87/CreateYourOwnMenus/git/trees{/sha}","statuses_url":"https://api.github.com/repos/XHawk87/CreateYourOwnMenus/statuses/{sha}","languages_url":"https://api.github.com/repos/XHawk87/CreateYourOwnMenus/languages","stargazers_url":"https://api.github.com/repos/XHawk87/CreateYourOwnMenus/stargazers","contributors_url":"https://api.github.com/repos/XHawk87/CreateYourOwnMenus/contributors","subscribers_url":"https://api.github.com/repos/XHawk87/CreateYourOwnMenus/subscribers","subscription_url":"https://api.github.com/repos/XHawk87/CreateYourOwnMenus/subscription","commits_url":"https://api.github.com/repos/XHawk87/CreateYourOwnMenus/commits{/sha}","git_commits_url":"https://api.github.com/repos/XHawk87/CreateYourOwnMenus/git/commits{/sha}","comments_url":"https://api.github.com/repos/XHawk87/CreateYourOwnMenus/comments{/number}","issue_comment_url":"https://api.github.com/repos/XHawk87/CreateYourOwnMenus/issues/comments{/number}","contents_url":"https://api.github.com/repos/XHawk87/CreateYourOwnMenus/contents/{+path}","compare_url":"https://api.github.com/repos/XHawk87/CreateYourOwnMenus/compare/{base}...{head}","merges_url":"https://api.github.com/repos/XHawk87/CreateYourOwnMenus/merges","archive_url":"https://api.github.com/repos/XHawk87/CreateYourOwnMenus/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/XHawk87/CreateYourOwnMenus/downloads","issues_url":"https://api.github.com/repos/XHawk87/CreateYourOwnMenus/issues{/number}","pulls_url":"https://api.github.com/repos/XHawk87/CreateYourOwnMenus/pulls{/number}","milestones_url":"https://api.github.com/repos/XHawk87/CreateYourOwnMenus/milestones{/number}","notifications_url":"https://api.github.com/repos/XHawk87/CreateYourOwnMenus/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/XHawk87/CreateYourOwnMenus/labels{/name}","releases_url":"https://api.github.com/repos/XHawk87/CreateYourOwnMenus/releases{/id}","deployments_url":"https://api.github.com/repos/XHawk87/CreateYourOwnMenus/deployments","created_at":"2013-06-18T15:41:40Z","updated_at":"2018-07-10T13:52:03Z","pushed_at":"2018-10-17T11:27:27Z","git_url":"git://github.com/XHawk87/CreateYourOwnMenus.git","ssh_url":"git@github.com:XHawk87/CreateYourOwnMenus.git","clone_url":"https://github.com/XHawk87/CreateYourOwnMenus.git","svn_url":"https://github.com/XHawk87/CreateYourOwnMenus","homepage":null,"size":216,"stargazers_count":5,"watchers_count":5,"language":"Java","has_issues":true,"has_projects":true,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":6,"mirror_url":null,"archived":false,"open_issues_count":3,"license":null,"forks":6,"open_issues":3,"watchers":5,"default_branch":"master"}},"_links":{"self":{"href":"https://api.github.com/repos/XHawk87/CreateYourOwnMenus/pulls/20"},"html":{"href":"https://github.com/XHawk87/CreateYourOwnMenus/pull/20"},"issue":{"href":"https://api.github.com/repos/XHawk87/CreateYourOwnMenus/issues/20"},"comments":{"href":"https://api.github.com/repos/XHawk87/CreateYourOwnMenus/issues/20/comments"},"review_comments":{"href":"https://api.github.com/repos/XHawk87/CreateYourOwnMenus/pulls/20/comments"},"review_comment":{"href":"https://api.github.com/repos/XHawk87/CreateYourOwnMenus/pulls/comments{/number}"},"commits":{"href":"https://api.github.com/repos/XHawk87/CreateYourOwnMenus/pulls/20/commits"},"statuses":{"href":"https://api.github.com/repos/XHawk87/CreateYourOwnMenus/statuses/bcd32131caaf2e1ab176067bcdc4adf489416166"}},"author_association":"NONE"}}
{"actor":{"display_login":"Peda1996"}}