{"action":"created","comment":{"url":"https://api.github.com/repos/platanus/vue-rut/pulls/comments/89646918","pull_request_review_id":10192479,"id":89646918,"diff_hunk":"@@ -0,0 +1,60 @@\n+'use strict';\n+\n+Object.defineProperty(exports, \"__esModule\", {\n+  value: true\n+});\n+exports.rutValidator = rutValidator;\n+exports.rutFilter = rutFilter;\n+/* eslint-disable no-magic-numbers, max-statements */\n+\n+function cleanRut(value) {\n+  return typeof value === 'string' ? value.replace(/[^0-9kK]+/g, '').toUpperCase() : '';\n+}\n+\n+function rutValidator(value) {\n+  if (typeof value !== 'string') {\n+    return false;\n+  }\n+\n+  var cleanValue = cleanRut(value);\n+  var t = parseInt(cleanValue.slice(0, -1), 10);\n+  var m = 0;\n+  var s = 1;\n+\n+  while (t > 0) {\n+    s = (s + t % 10 * (9 - m++ % 6)) % 11;\n+    t = Math.floor(t / 10);\n+  }\n+\n+  var v = s > 0 ? '' + (s - 1) : 'K';\n+\n+  return v === cleanValue.slice(-1);\n+}\n+\n+function rutFilter(value) {\n+  var cleanValue = cleanRut(value);\n+  var result = void 0;\n+\n+  if (cleanValue.length <= 1) {\n+    result = cleanValue;\n+  } else {\n+    result = cleanValue.slice(-4, -1) + '-' + cleanValue.substr(cleanValue.length - 1);\n+    for (var i = 4; i < cleanValue.length; i += 3) {\n+      result = cleanValue.slice(-3 - i, -i) + '.' + result;\n+    }\n+  }\n+\n+  return result;\n+}\n+\n+var rutInputDirective = exports.rutInputDirective = {","path":"dist/vue-rut.js","position":50,"original_position":50,"commit_id":"95ee3cbc61c415a8ab225c06f19eaa8ce43db88e","original_commit_id":"95ee3cbc61c415a8ab225c06f19eaa8ce43db88e","user":{"login":"monkeyci","id":11537867,"avatar_url":"https://avatars.githubusercontent.com/u/11537867?v=3","gravatar_id":"","url":"https://api.github.com/users/monkeyci","html_url":"https://github.com/monkeyci","followers_url":"https://api.github.com/users/monkeyci/followers","following_url":"https://api.github.com/users/monkeyci/following{/other_user}","gists_url":"https://api.github.com/users/monkeyci/gists{/gist_id}","starred_url":"https://api.github.com/users/monkeyci/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/monkeyci/subscriptions","organizations_url":"https://api.github.com/users/monkeyci/orgs","repos_url":"https://api.github.com/users/monkeyci/repos","events_url":"https://api.github.com/users/monkeyci/events{/privacy}","received_events_url":"https://api.github.com/users/monkeyci/received_events","type":"User","site_admin":false},"body":"'exports' is not defined.<br>'rutInputDirective' is defined but never used.","created_at":"2016-11-25T17:55:52Z","updated_at":"2016-11-25T17:55:52Z","html_url":"https://github.com/platanus/vue-rut/pull/1#discussion_r89646918","pull_request_url":"https://api.github.com/repos/platanus/vue-rut/pulls/1","_links":{"self":{"href":"https://api.github.com/repos/platanus/vue-rut/pulls/comments/89646918"},"html":{"href":"https://github.com/platanus/vue-rut/pull/1#discussion_r89646918"},"pull_request":{"href":"https://api.github.com/repos/platanus/vue-rut/pulls/1"}}},"pull_request":{"url":"https://api.github.com/repos/platanus/vue-rut/pulls/1","id":95336154,"html_url":"https://github.com/platanus/vue-rut/pull/1","diff_url":"https://github.com/platanus/vue-rut/pull/1.diff","patch_url":"https://github.com/platanus/vue-rut/pull/1.patch","issue_url":"https://api.github.com/repos/platanus/vue-rut/issues/1","number":1,"state":"open","locked":false,"title":"first commit","user":{"login":"gmq","id":472791,"avatar_url":"https://avatars.githubusercontent.com/u/472791?v=3","gravatar_id":"","url":"https://api.github.com/users/gmq","html_url":"https://github.com/gmq","followers_url":"https://api.github.com/users/gmq/followers","following_url":"https://api.github.com/users/gmq/following{/other_user}","gists_url":"https://api.github.com/users/gmq/gists{/gist_id}","starred_url":"https://api.github.com/users/gmq/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/gmq/subscriptions","organizations_url":"https://api.github.com/users/gmq/orgs","repos_url":"https://api.github.com/users/gmq/repos","events_url":"https://api.github.com/users/gmq/events{/privacy}","received_events_url":"https://api.github.com/users/gmq/received_events","type":"User","site_admin":false},"body":"","created_at":"2016-11-25T17:55:43Z","updated_at":"2016-11-25T17:55:52Z","closed_at":null,"merged_at":null,"merge_commit_sha":"640a47ea03732f05abf2c636a476679846080b0c","assignee":null,"assignees":[],"milestone":null,"commits_url":"https://api.github.com/repos/platanus/vue-rut/pulls/1/commits","review_comments_url":"https://api.github.com/repos/platanus/vue-rut/pulls/1/comments","review_comment_url":"https://api.github.com/repos/platanus/vue-rut/pulls/comments{/number}","comments_url":"https://api.github.com/repos/platanus/vue-rut/issues/1/comments","statuses_url":"https://api.github.com/repos/platanus/vue-rut/statuses/95ee3cbc61c415a8ab225c06f19eaa8ce43db88e","head":{"label":"platanus:implementation","ref":"implementation","sha":"95ee3cbc61c415a8ab225c06f19eaa8ce43db88e","user":{"login":"platanus","id":1158740,"avatar_url":"https://avatars.githubusercontent.com/u/1158740?v=3","gravatar_id":"","url":"https://api.github.com/users/platanus","html_url":"https://github.com/platanus","followers_url":"https://api.github.com/users/platanus/followers","following_url":"https://api.github.com/users/platanus/following{/other_user}","gists_url":"https://api.github.com/users/platanus/gists{/gist_id}","starred_url":"https://api.github.com/users/platanus/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/platanus/subscriptions","organizations_url":"https://api.github.com/users/platanus/orgs","repos_url":"https://api.github.com/users/platanus/repos","events_url":"https://api.github.com/users/platanus/events{/privacy}","received_events_url":"https://api.github.com/users/platanus/received_events","type":"Organization","site_admin":false},"repo":{"id":74769551,"name":"vue-rut","full_name":"platanus/vue-rut","owner":{"login":"platanus","id":1158740,"avatar_url":"https://avatars.githubusercontent.com/u/1158740?v=3","gravatar_id":"","url":"https://api.github.com/users/platanus","html_url":"https://github.com/platanus","followers_url":"https://api.github.com/users/platanus/followers","following_url":"https://api.github.com/users/platanus/following{/other_user}","gists_url":"https://api.github.com/users/platanus/gists{/gist_id}","starred_url":"https://api.github.com/users/platanus/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/platanus/subscriptions","organizations_url":"https://api.github.com/users/platanus/orgs","repos_url":"https://api.github.com/users/platanus/repos","events_url":"https://api.github.com/users/platanus/events{/privacy}","received_events_url":"https://api.github.com/users/platanus/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/platanus/vue-rut","description":null,"fork":false,"url":"https://api.github.com/repos/platanus/vue-rut","forks_url":"https://api.github.com/repos/platanus/vue-rut/forks","keys_url":"https://api.github.com/repos/platanus/vue-rut/keys{/key_id}","collaborators_url":"https://api.github.com/repos/platanus/vue-rut/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/platanus/vue-rut/teams","hooks_url":"https://api.github.com/repos/platanus/vue-rut/hooks","issue_events_url":"https://api.github.com/repos/platanus/vue-rut/issues/events{/number}","events_url":"https://api.github.com/repos/platanus/vue-rut/events","assignees_url":"https://api.github.com/repos/platanus/vue-rut/assignees{/user}","branches_url":"https://api.github.com/repos/platanus/vue-rut/branches{/branch}","tags_url":"https://api.github.com/repos/platanus/vue-rut/tags","blobs_url":"https://api.github.com/repos/platanus/vue-rut/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/platanus/vue-rut/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/platanus/vue-rut/git/refs{/sha}","trees_url":"https://api.github.com/repos/platanus/vue-rut/git/trees{/sha}","statuses_url":"https://api.github.com/repos/platanus/vue-rut/statuses/{sha}","languages_url":"https://api.github.com/repos/platanus/vue-rut/languages","stargazers_url":"https://api.github.com/repos/platanus/vue-rut/stargazers","contributors_url":"https://api.github.com/repos/platanus/vue-rut/contributors","subscribers_url":"https://api.github.com/repos/platanus/vue-rut/subscribers","subscription_url":"https://api.github.com/repos/platanus/vue-rut/subscription","commits_url":"https://api.github.com/repos/platanus/vue-rut/commits{/sha}","git_commits_url":"https://api.github.com/repos/platanus/vue-rut/git/commits{/sha}","comments_url":"https://api.github.com/repos/platanus/vue-rut/comments{/number}","issue_comment_url":"https://api.github.com/repos/platanus/vue-rut/issues/comments{/number}","contents_url":"https://api.github.com/repos/platanus/vue-rut/contents/{+path}","compare_url":"https://api.github.com/repos/platanus/vue-rut/compare/{base}...{head}","merges_url":"https://api.github.com/repos/platanus/vue-rut/merges","archive_url":"https://api.github.com/repos/platanus/vue-rut/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/platanus/vue-rut/downloads","issues_url":"https://api.github.com/repos/platanus/vue-rut/issues{/number}","pulls_url":"https://api.github.com/repos/platanus/vue-rut/pulls{/number}","milestones_url":"https://api.github.com/repos/platanus/vue-rut/milestones{/number}","notifications_url":"https://api.github.com/repos/platanus/vue-rut/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/platanus/vue-rut/labels{/name}","releases_url":"https://api.github.com/repos/platanus/vue-rut/releases{/id}","deployments_url":"https://api.github.com/repos/platanus/vue-rut/deployments","created_at":"2016-11-25T15:31:14Z","updated_at":"2016-11-25T17:54:59Z","pushed_at":"2016-11-25T17:55:43Z","git_url":"git://github.com/platanus/vue-rut.git","ssh_url":"git@github.com:platanus/vue-rut.git","clone_url":"https://github.com/platanus/vue-rut.git","svn_url":"https://github.com/platanus/vue-rut","homepage":null,"size":0,"stargazers_count":0,"watchers_count":0,"language":"JavaScript","has_issues":true,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":0,"mirror_url":null,"open_issues_count":1,"forks":0,"open_issues":1,"watchers":0,"default_branch":"master"}},"base":{"label":"platanus:master","ref":"master","sha":"ba20f7928105b2f70b356f15501025b1a993daa5","user":{"login":"platanus","id":1158740,"avatar_url":"https://avatars.githubusercontent.com/u/1158740?v=3","gravatar_id":"","url":"https://api.github.com/users/platanus","html_url":"https://github.com/platanus","followers_url":"https://api.github.com/users/platanus/followers","following_url":"https://api.github.com/users/platanus/following{/other_user}","gists_url":"https://api.github.com/users/platanus/gists{/gist_id}","starred_url":"https://api.github.com/users/platanus/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/platanus/subscriptions","organizations_url":"https://api.github.com/users/platanus/orgs","repos_url":"https://api.github.com/users/platanus/repos","events_url":"https://api.github.com/users/platanus/events{/privacy}","received_events_url":"https://api.github.com/users/platanus/received_events","type":"Organization","site_admin":false},"repo":{"id":74769551,"name":"vue-rut","full_name":"platanus/vue-rut","owner":{"login":"platanus","id":1158740,"avatar_url":"https://avatars.githubusercontent.com/u/1158740?v=3","gravatar_id":"","url":"https://api.github.com/users/platanus","html_url":"https://github.com/platanus","followers_url":"https://api.github.com/users/platanus/followers","following_url":"https://api.github.com/users/platanus/following{/other_user}","gists_url":"https://api.github.com/users/platanus/gists{/gist_id}","starred_url":"https://api.github.com/users/platanus/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/platanus/subscriptions","organizations_url":"https://api.github.com/users/platanus/orgs","repos_url":"https://api.github.com/users/platanus/repos","events_url":"https://api.github.com/users/platanus/events{/privacy}","received_events_url":"https://api.github.com/users/platanus/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/platanus/vue-rut","description":null,"fork":false,"url":"https://api.github.com/repos/platanus/vue-rut","forks_url":"https://api.github.com/repos/platanus/vue-rut/forks","keys_url":"https://api.github.com/repos/platanus/vue-rut/keys{/key_id}","collaborators_url":"https://api.github.com/repos/platanus/vue-rut/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/platanus/vue-rut/teams","hooks_url":"https://api.github.com/repos/platanus/vue-rut/hooks","issue_events_url":"https://api.github.com/repos/platanus/vue-rut/issues/events{/number}","events_url":"https://api.github.com/repos/platanus/vue-rut/events","assignees_url":"https://api.github.com/repos/platanus/vue-rut/assignees{/user}","branches_url":"https://api.github.com/repos/platanus/vue-rut/branches{/branch}","tags_url":"https://api.github.com/repos/platanus/vue-rut/tags","blobs_url":"https://api.github.com/repos/platanus/vue-rut/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/platanus/vue-rut/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/platanus/vue-rut/git/refs{/sha}","trees_url":"https://api.github.com/repos/platanus/vue-rut/git/trees{/sha}","statuses_url":"https://api.github.com/repos/platanus/vue-rut/statuses/{sha}","languages_url":"https://api.github.com/repos/platanus/vue-rut/languages","stargazers_url":"https://api.github.com/repos/platanus/vue-rut/stargazers","contributors_url":"https://api.github.com/repos/platanus/vue-rut/contributors","subscribers_url":"https://api.github.com/repos/platanus/vue-rut/subscribers","subscription_url":"https://api.github.com/repos/platanus/vue-rut/subscription","commits_url":"https://api.github.com/repos/platanus/vue-rut/commits{/sha}","git_commits_url":"https://api.github.com/repos/platanus/vue-rut/git/commits{/sha}","comments_url":"https://api.github.com/repos/platanus/vue-rut/comments{/number}","issue_comment_url":"https://api.github.com/repos/platanus/vue-rut/issues/comments{/number}","contents_url":"https://api.github.com/repos/platanus/vue-rut/contents/{+path}","compare_url":"https://api.github.com/repos/platanus/vue-rut/compare/{base}...{head}","merges_url":"https://api.github.com/repos/platanus/vue-rut/merges","archive_url":"https://api.github.com/repos/platanus/vue-rut/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/platanus/vue-rut/downloads","issues_url":"https://api.github.com/repos/platanus/vue-rut/issues{/number}","pulls_url":"https://api.github.com/repos/platanus/vue-rut/pulls{/number}","milestones_url":"https://api.github.com/repos/platanus/vue-rut/milestones{/number}","notifications_url":"https://api.github.com/repos/platanus/vue-rut/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/platanus/vue-rut/labels{/name}","releases_url":"https://api.github.com/repos/platanus/vue-rut/releases{/id}","deployments_url":"https://api.github.com/repos/platanus/vue-rut/deployments","created_at":"2016-11-25T15:31:14Z","updated_at":"2016-11-25T17:54:59Z","pushed_at":"2016-11-25T17:55:43Z","git_url":"git://github.com/platanus/vue-rut.git","ssh_url":"git@github.com:platanus/vue-rut.git","clone_url":"https://github.com/platanus/vue-rut.git","svn_url":"https://github.com/platanus/vue-rut","homepage":null,"size":0,"stargazers_count":0,"watchers_count":0,"language":"JavaScript","has_issues":true,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":0,"mirror_url":null,"open_issues_count":1,"forks":0,"open_issues":1,"watchers":0,"default_branch":"master"}},"_links":{"self":{"href":"https://api.github.com/repos/platanus/vue-rut/pulls/1"},"html":{"href":"https://github.com/platanus/vue-rut/pull/1"},"issue":{"href":"https://api.github.com/repos/platanus/vue-rut/issues/1"},"comments":{"href":"https://api.github.com/repos/platanus/vue-rut/issues/1/comments"},"review_comments":{"href":"https://api.github.com/repos/platanus/vue-rut/pulls/1/comments"},"review_comment":{"href":"https://api.github.com/repos/platanus/vue-rut/pulls/comments{/number}"},"commits":{"href":"https://api.github.com/repos/platanus/vue-rut/pulls/1/commits"},"statuses":{"href":"https://api.github.com/repos/platanus/vue-rut/statuses/95ee3cbc61c415a8ab225c06f19eaa8ce43db88e"}}}}
{"actor":{"display_login":"monkeyci"}}