{"action":"created","comment":{"url":"https://api.github.com/repos/webpack-contrib/copy-webpack-plugin/pulls/comments/223075883","pull_request_review_id":162122401,"id":223075883,"node_id":"MDI0OlB1bGxSZXF1ZXN0UmV2aWV3Q29tbWVudDIyMzA3NTg4Mw==","diff_hunk":"@@ -60,43 +65,43 @@ export default function preProcessPattern(globalRef, pattern) {\n     debug(`determined '${pattern.from}' to be read from '${pattern.absoluteFrom}'`);\n \n     return stat(inputFileSystem, pattern.absoluteFrom)\n-    .catch(() => {\n+        .catch(() => {\n         // If from doesn't appear to be a glob, then log a warning\n-        if (isGlob(pattern.from) || pattern.from.indexOf('*') !== -1) {\n-            pattern.fromType = 'glob';\n-            pattern.glob = escape(pattern.context, pattern.from);\n-        } else {\n-            const msg = `unable to locate '${pattern.from}' at '${pattern.absoluteFrom}'`;\n-            warning(msg);\n-            compilation.errors.push(`[copy-webpack-plugin] ${msg}`);\n-            pattern.fromType = 'nonexistent';\n-        }\n-    })\n-    .then((stat) => {\n-        if (!stat) {\n-            return pattern;\n-        }\n+            if (isGlob(pattern.from) || pattern.from.indexOf('*') !== -1) {\n+                pattern.fromType = 'glob';\n+                pattern.glob = escape(pattern.context, pattern.from);\n+            } else {\n+                const msg = `unable to locate '${pattern.from}' at '${pattern.absoluteFrom}'`;\n+                warning(msg);\n+                compilation.errors.push(`[copy-webpack-plugin] ${msg}`);\n+                pattern.fromType = 'nonexistent';\n+            }\n+        })\n+        .then((stat) => {\n+            if (!stat) {\n+                return pattern;\n+            }\n \n-        if (stat.isDirectory()) {\n-            pattern.fromType = 'dir';\n-            pattern.context = pattern.absoluteFrom;\n-            contextDependencies.push(pattern.absoluteFrom);\n-            pattern.glob = escape(pattern.absoluteFrom, '**/*');\n-            pattern.absoluteFrom = path.join(pattern.absoluteFrom, '**/*');\n-            pattern.fromArgs = {\n-                dot: true\n-            };\n-        } else if(stat.isFile()) {\n-            pattern.fromType = 'file';\n-            pattern.context = path.dirname(pattern.absoluteFrom);\n-            pattern.glob = escape(pattern.absoluteFrom);\n-            pattern.fromArgs = {\n-                dot: true\n-            };\n-            fileDependencies.push(pattern.absoluteFrom);\n-        } else if(!pattern.fromType) {\n-            info(`Unrecognized file type for ${pattern.from}`);\n-        }\n-        return pattern;\n-    });\n+            if (stat.isDirectory()) {\n+                pattern.fromType = 'dir';\n+                pattern.context = pattern.absoluteFrom;\n+                contextDependencies.push(pattern.absoluteFrom);\n+                pattern.glob = escape(pattern.absoluteFrom, '**/*');\n+                pattern.absoluteFrom = path.join(pattern.absoluteFrom, '**/*');\n+                pattern.fromArgs = {\n+                    dot: true\n+                };\n+            } else if(stat.isFile()) {\n+                pattern.fromType = 'file';\n+                pattern.context = path.dirname(pattern.absoluteFrom);\n+                pattern.glob = escape(pattern.absoluteFrom);\n+                pattern.fromArgs = {\n+                    dot: true\n+                };\n+                fileDependencies.push(pattern.absoluteFrom);\n+            } else if(!pattern.fromType) {\n+                info(`Unrecognized file type for ${pattern.from}`);\n+            }\n+            return pattern;\n+        });","path":"src/preProcessPattern.js","position":91,"original_position":91,"commit_id":"326fc3f14ec83e6333b8aee1a40a1c02625fc878","original_commit_id":"326fc3f14ec83e6333b8aee1a40a1c02625fc878","user":{"login":"evilebottnawi","id":4567934,"node_id":"MDQ6VXNlcjQ1Njc5MzQ=","avatar_url":"https://avatars3.githubusercontent.com/u/4567934?v=4","gravatar_id":"","url":"https://api.github.com/users/evilebottnawi","html_url":"https://github.com/evilebottnawi","followers_url":"https://api.github.com/users/evilebottnawi/followers","following_url":"https://api.github.com/users/evilebottnawi/following{/other_user}","gists_url":"https://api.github.com/users/evilebottnawi/gists{/gist_id}","starred_url":"https://api.github.com/users/evilebottnawi/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/evilebottnawi/subscriptions","organizations_url":"https://api.github.com/users/evilebottnawi/orgs","repos_url":"https://api.github.com/users/evilebottnawi/repos","events_url":"https://api.github.com/users/evilebottnawi/events{/privacy}","received_events_url":"https://api.github.com/users/evilebottnawi/received_events","type":"User","site_admin":false},"body":"Avoid modify code style","created_at":"2018-10-05T17:00:55Z","updated_at":"2018-10-05T17:01:40Z","html_url":"https://github.com/webpack-contrib/copy-webpack-plugin/pull/295#discussion_r223075883","pull_request_url":"https://api.github.com/repos/webpack-contrib/copy-webpack-plugin/pulls/295","author_association":"MEMBER","_links":{"self":{"href":"https://api.github.com/repos/webpack-contrib/copy-webpack-plugin/pulls/comments/223075883"},"html":{"href":"https://github.com/webpack-contrib/copy-webpack-plugin/pull/295#discussion_r223075883"},"pull_request":{"href":"https://api.github.com/repos/webpack-contrib/copy-webpack-plugin/pulls/295"}}},"pull_request":{"url":"https://api.github.com/repos/webpack-contrib/copy-webpack-plugin/pulls/295","id":220764044,"node_id":"MDExOlB1bGxSZXF1ZXN0MjIwNzY0MDQ0","html_url":"https://github.com/webpack-contrib/copy-webpack-plugin/pull/295","diff_url":"https://github.com/webpack-contrib/copy-webpack-plugin/pull/295.diff","patch_url":"https://github.com/webpack-contrib/copy-webpack-plugin/pull/295.patch","issue_url":"https://api.github.com/repos/webpack-contrib/copy-webpack-plugin/issues/295","number":295,"state":"open","locked":false,"title":"feat(ignoreFn): added an ignore function to allow granular file exclusions","user":{"login":"ivansieder","id":35377072,"node_id":"MDQ6VXNlcjM1Mzc3MDcy","avatar_url":"https://avatars1.githubusercontent.com/u/35377072?v=4","gravatar_id":"","url":"https://api.github.com/users/ivansieder","html_url":"https://github.com/ivansieder","followers_url":"https://api.github.com/users/ivansieder/followers","following_url":"https://api.github.com/users/ivansieder/following{/other_user}","gists_url":"https://api.github.com/users/ivansieder/gists{/gist_id}","starred_url":"https://api.github.com/users/ivansieder/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/ivansieder/subscriptions","organizations_url":"https://api.github.com/users/ivansieder/orgs","repos_url":"https://api.github.com/users/ivansieder/repos","events_url":"https://api.github.com/users/ivansieder/events{/privacy}","received_events_url":"https://api.github.com/users/ivansieder/received_events","type":"User","site_admin":false},"body":"Refers to #294 ","created_at":"2018-10-05T16:54:21Z","updated_at":"2018-10-05T17:01:40Z","closed_at":null,"merged_at":null,"merge_commit_sha":"5f51548a98c3d7448145385d2f24b37385d412e1","assignee":null,"assignees":[],"requested_reviewers":[],"requested_teams":[],"labels":[],"milestone":null,"commits_url":"https://api.github.com/repos/webpack-contrib/copy-webpack-plugin/pulls/295/commits","review_comments_url":"https://api.github.com/repos/webpack-contrib/copy-webpack-plugin/pulls/295/comments","review_comment_url":"https://api.github.com/repos/webpack-contrib/copy-webpack-plugin/pulls/comments{/number}","comments_url":"https://api.github.com/repos/webpack-contrib/copy-webpack-plugin/issues/295/comments","statuses_url":"https://api.github.com/repos/webpack-contrib/copy-webpack-plugin/statuses/326fc3f14ec83e6333b8aee1a40a1c02625fc878","head":{"label":"ivansieder:master","ref":"master","sha":"326fc3f14ec83e6333b8aee1a40a1c02625fc878","user":{"login":"ivansieder","id":35377072,"node_id":"MDQ6VXNlcjM1Mzc3MDcy","avatar_url":"https://avatars1.githubusercontent.com/u/35377072?v=4","gravatar_id":"","url":"https://api.github.com/users/ivansieder","html_url":"https://github.com/ivansieder","followers_url":"https://api.github.com/users/ivansieder/followers","following_url":"https://api.github.com/users/ivansieder/following{/other_user}","gists_url":"https://api.github.com/users/ivansieder/gists{/gist_id}","starred_url":"https://api.github.com/users/ivansieder/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/ivansieder/subscriptions","organizations_url":"https://api.github.com/users/ivansieder/orgs","repos_url":"https://api.github.com/users/ivansieder/repos","events_url":"https://api.github.com/users/ivansieder/events{/privacy}","received_events_url":"https://api.github.com/users/ivansieder/received_events","type":"User","site_admin":false},"repo":{"id":151742771,"node_id":"MDEwOlJlcG9zaXRvcnkxNTE3NDI3NzE=","name":"copy-webpack-plugin","full_name":"ivansieder/copy-webpack-plugin","private":false,"owner":{"login":"ivansieder","id":35377072,"node_id":"MDQ6VXNlcjM1Mzc3MDcy","avatar_url":"https://avatars1.githubusercontent.com/u/35377072?v=4","gravatar_id":"","url":"https://api.github.com/users/ivansieder","html_url":"https://github.com/ivansieder","followers_url":"https://api.github.com/users/ivansieder/followers","following_url":"https://api.github.com/users/ivansieder/following{/other_user}","gists_url":"https://api.github.com/users/ivansieder/gists{/gist_id}","starred_url":"https://api.github.com/users/ivansieder/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/ivansieder/subscriptions","organizations_url":"https://api.github.com/users/ivansieder/orgs","repos_url":"https://api.github.com/users/ivansieder/repos","events_url":"https://api.github.com/users/ivansieder/events{/privacy}","received_events_url":"https://api.github.com/users/ivansieder/received_events","type":"User","site_admin":false},"html_url":"https://github.com/ivansieder/copy-webpack-plugin","description":"Copy files and directories with webpack","fork":true,"url":"https://api.github.com/repos/ivansieder/copy-webpack-plugin","forks_url":"https://api.github.com/repos/ivansieder/copy-webpack-plugin/forks","keys_url":"https://api.github.com/repos/ivansieder/copy-webpack-plugin/keys{/key_id}","collaborators_url":"https://api.github.com/repos/ivansieder/copy-webpack-plugin/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/ivansieder/copy-webpack-plugin/teams","hooks_url":"https://api.github.com/repos/ivansieder/copy-webpack-plugin/hooks","issue_events_url":"https://api.github.com/repos/ivansieder/copy-webpack-plugin/issues/events{/number}","events_url":"https://api.github.com/repos/ivansieder/copy-webpack-plugin/events","assignees_url":"https://api.github.com/repos/ivansieder/copy-webpack-plugin/assignees{/user}","branches_url":"https://api.github.com/repos/ivansieder/copy-webpack-plugin/branches{/branch}","tags_url":"https://api.github.com/repos/ivansieder/copy-webpack-plugin/tags","blobs_url":"https://api.github.com/repos/ivansieder/copy-webpack-plugin/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/ivansieder/copy-webpack-plugin/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/ivansieder/copy-webpack-plugin/git/refs{/sha}","trees_url":"https://api.github.com/repos/ivansieder/copy-webpack-plugin/git/trees{/sha}","statuses_url":"https://api.github.com/repos/ivansieder/copy-webpack-plugin/statuses/{sha}","languages_url":"https://api.github.com/repos/ivansieder/copy-webpack-plugin/languages","stargazers_url":"https://api.github.com/repos/ivansieder/copy-webpack-plugin/stargazers","contributors_url":"https://api.github.com/repos/ivansieder/copy-webpack-plugin/contributors","subscribers_url":"https://api.github.com/repos/ivansieder/copy-webpack-plugin/subscribers","subscription_url":"https://api.github.com/repos/ivansieder/copy-webpack-plugin/subscription","commits_url":"https://api.github.com/repos/ivansieder/copy-webpack-plugin/commits{/sha}","git_commits_url":"https://api.github.com/repos/ivansieder/copy-webpack-plugin/git/commits{/sha}","comments_url":"https://api.github.com/repos/ivansieder/copy-webpack-plugin/comments{/number}","issue_comment_url":"https://api.github.com/repos/ivansieder/copy-webpack-plugin/issues/comments{/number}","contents_url":"https://api.github.com/repos/ivansieder/copy-webpack-plugin/contents/{+path}","compare_url":"https://api.github.com/repos/ivansieder/copy-webpack-plugin/compare/{base}...{head}","merges_url":"https://api.github.com/repos/ivansieder/copy-webpack-plugin/merges","archive_url":"https://api.github.com/repos/ivansieder/copy-webpack-plugin/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/ivansieder/copy-webpack-plugin/downloads","issues_url":"https://api.github.com/repos/ivansieder/copy-webpack-plugin/issues{/number}","pulls_url":"https://api.github.com/repos/ivansieder/copy-webpack-plugin/pulls{/number}","milestones_url":"https://api.github.com/repos/ivansieder/copy-webpack-plugin/milestones{/number}","notifications_url":"https://api.github.com/repos/ivansieder/copy-webpack-plugin/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/ivansieder/copy-webpack-plugin/labels{/name}","releases_url":"https://api.github.com/repos/ivansieder/copy-webpack-plugin/releases{/id}","deployments_url":"https://api.github.com/repos/ivansieder/copy-webpack-plugin/deployments","created_at":"2018-10-05T15:38:16Z","updated_at":"2018-10-05T16:52:18Z","pushed_at":"2018-10-05T16:52:15Z","git_url":"git://github.com/ivansieder/copy-webpack-plugin.git","ssh_url":"git@github.com:ivansieder/copy-webpack-plugin.git","clone_url":"https://github.com/ivansieder/copy-webpack-plugin.git","svn_url":"https://github.com/ivansieder/copy-webpack-plugin","homepage":"","size":334,"stargazers_count":0,"watchers_count":0,"language":"JavaScript","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":"webpack-contrib:master","ref":"master","sha":"5fa69db9b07653180f8bc089de27dfdd7c7d8d7e","user":{"login":"webpack-contrib","id":25012217,"node_id":"MDEyOk9yZ2FuaXphdGlvbjI1MDEyMjE3","avatar_url":"https://avatars3.githubusercontent.com/u/25012217?v=4","gravatar_id":"","url":"https://api.github.com/users/webpack-contrib","html_url":"https://github.com/webpack-contrib","followers_url":"https://api.github.com/users/webpack-contrib/followers","following_url":"https://api.github.com/users/webpack-contrib/following{/other_user}","gists_url":"https://api.github.com/users/webpack-contrib/gists{/gist_id}","starred_url":"https://api.github.com/users/webpack-contrib/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/webpack-contrib/subscriptions","organizations_url":"https://api.github.com/users/webpack-contrib/orgs","repos_url":"https://api.github.com/users/webpack-contrib/repos","events_url":"https://api.github.com/users/webpack-contrib/events{/privacy}","received_events_url":"https://api.github.com/users/webpack-contrib/received_events","type":"Organization","site_admin":false},"repo":{"id":45010048,"node_id":"MDEwOlJlcG9zaXRvcnk0NTAxMDA0OA==","name":"copy-webpack-plugin","full_name":"webpack-contrib/copy-webpack-plugin","private":false,"owner":{"login":"webpack-contrib","id":25012217,"node_id":"MDEyOk9yZ2FuaXphdGlvbjI1MDEyMjE3","avatar_url":"https://avatars3.githubusercontent.com/u/25012217?v=4","gravatar_id":"","url":"https://api.github.com/users/webpack-contrib","html_url":"https://github.com/webpack-contrib","followers_url":"https://api.github.com/users/webpack-contrib/followers","following_url":"https://api.github.com/users/webpack-contrib/following{/other_user}","gists_url":"https://api.github.com/users/webpack-contrib/gists{/gist_id}","starred_url":"https://api.github.com/users/webpack-contrib/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/webpack-contrib/subscriptions","organizations_url":"https://api.github.com/users/webpack-contrib/orgs","repos_url":"https://api.github.com/users/webpack-contrib/repos","events_url":"https://api.github.com/users/webpack-contrib/events{/privacy}","received_events_url":"https://api.github.com/users/webpack-contrib/received_events","type":"Organization","site_admin":false},"html_url":"https://github.com/webpack-contrib/copy-webpack-plugin","description":"Copy files and directories with webpack","fork":false,"url":"https://api.github.com/repos/webpack-contrib/copy-webpack-plugin","forks_url":"https://api.github.com/repos/webpack-contrib/copy-webpack-plugin/forks","keys_url":"https://api.github.com/repos/webpack-contrib/copy-webpack-plugin/keys{/key_id}","collaborators_url":"https://api.github.com/repos/webpack-contrib/copy-webpack-plugin/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/webpack-contrib/copy-webpack-plugin/teams","hooks_url":"https://api.github.com/repos/webpack-contrib/copy-webpack-plugin/hooks","issue_events_url":"https://api.github.com/repos/webpack-contrib/copy-webpack-plugin/issues/events{/number}","events_url":"https://api.github.com/repos/webpack-contrib/copy-webpack-plugin/events","assignees_url":"https://api.github.com/repos/webpack-contrib/copy-webpack-plugin/assignees{/user}","branches_url":"https://api.github.com/repos/webpack-contrib/copy-webpack-plugin/branches{/branch}","tags_url":"https://api.github.com/repos/webpack-contrib/copy-webpack-plugin/tags","blobs_url":"https://api.github.com/repos/webpack-contrib/copy-webpack-plugin/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/webpack-contrib/copy-webpack-plugin/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/webpack-contrib/copy-webpack-plugin/git/refs{/sha}","trees_url":"https://api.github.com/repos/webpack-contrib/copy-webpack-plugin/git/trees{/sha}","statuses_url":"https://api.github.com/repos/webpack-contrib/copy-webpack-plugin/statuses/{sha}","languages_url":"https://api.github.com/repos/webpack-contrib/copy-webpack-plugin/languages","stargazers_url":"https://api.github.com/repos/webpack-contrib/copy-webpack-plugin/stargazers","contributors_url":"https://api.github.com/repos/webpack-contrib/copy-webpack-plugin/contributors","subscribers_url":"https://api.github.com/repos/webpack-contrib/copy-webpack-plugin/subscribers","subscription_url":"https://api.github.com/repos/webpack-contrib/copy-webpack-plugin/subscription","commits_url":"https://api.github.com/repos/webpack-contrib/copy-webpack-plugin/commits{/sha}","git_commits_url":"https://api.github.com/repos/webpack-contrib/copy-webpack-plugin/git/commits{/sha}","comments_url":"https://api.github.com/repos/webpack-contrib/copy-webpack-plugin/comments{/number}","issue_comment_url":"https://api.github.com/repos/webpack-contrib/copy-webpack-plugin/issues/comments{/number}","contents_url":"https://api.github.com/repos/webpack-contrib/copy-webpack-plugin/contents/{+path}","compare_url":"https://api.github.com/repos/webpack-contrib/copy-webpack-plugin/compare/{base}...{head}","merges_url":"https://api.github.com/repos/webpack-contrib/copy-webpack-plugin/merges","archive_url":"https://api.github.com/repos/webpack-contrib/copy-webpack-plugin/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/webpack-contrib/copy-webpack-plugin/downloads","issues_url":"https://api.github.com/repos/webpack-contrib/copy-webpack-plugin/issues{/number}","pulls_url":"https://api.github.com/repos/webpack-contrib/copy-webpack-plugin/pulls{/number}","milestones_url":"https://api.github.com/repos/webpack-contrib/copy-webpack-plugin/milestones{/number}","notifications_url":"https://api.github.com/repos/webpack-contrib/copy-webpack-plugin/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/webpack-contrib/copy-webpack-plugin/labels{/name}","releases_url":"https://api.github.com/repos/webpack-contrib/copy-webpack-plugin/releases{/id}","deployments_url":"https://api.github.com/repos/webpack-contrib/copy-webpack-plugin/deployments","created_at":"2015-10-27T01:53:16Z","updated_at":"2018-10-05T06:56:21Z","pushed_at":"2018-10-05T16:54:22Z","git_url":"git://github.com/webpack-contrib/copy-webpack-plugin.git","ssh_url":"git@github.com:webpack-contrib/copy-webpack-plugin.git","clone_url":"https://github.com/webpack-contrib/copy-webpack-plugin.git","svn_url":"https://github.com/webpack-contrib/copy-webpack-plugin","homepage":"","size":334,"stargazers_count":1711,"watchers_count":1711,"language":"JavaScript","has_issues":true,"has_projects":true,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":157,"mirror_url":null,"archived":false,"open_issues_count":42,"license":{"key":"mit","name":"MIT License","spdx_id":"MIT","url":"https://api.github.com/licenses/mit","node_id":"MDc6TGljZW5zZTEz"},"forks":157,"open_issues":42,"watchers":1711,"default_branch":"master"}},"_links":{"self":{"href":"https://api.github.com/repos/webpack-contrib/copy-webpack-plugin/pulls/295"},"html":{"href":"https://github.com/webpack-contrib/copy-webpack-plugin/pull/295"},"issue":{"href":"https://api.github.com/repos/webpack-contrib/copy-webpack-plugin/issues/295"},"comments":{"href":"https://api.github.com/repos/webpack-contrib/copy-webpack-plugin/issues/295/comments"},"review_comments":{"href":"https://api.github.com/repos/webpack-contrib/copy-webpack-plugin/pulls/295/comments"},"review_comment":{"href":"https://api.github.com/repos/webpack-contrib/copy-webpack-plugin/pulls/comments{/number}"},"commits":{"href":"https://api.github.com/repos/webpack-contrib/copy-webpack-plugin/pulls/295/commits"},"statuses":{"href":"https://api.github.com/repos/webpack-contrib/copy-webpack-plugin/statuses/326fc3f14ec83e6333b8aee1a40a1c02625fc878"}},"author_association":"NONE"}}
{"actor":{"display_login":"evilebottnawi"}}