{"action":"created","comment":{"url":"https://api.github.com/repos/framgia/fels_66/pulls/comments/33901509","id":33901509,"diff_hunk":"@@ -4,4 +4,10 @@ class Word < ActiveRecord::Base\n   has_many :results, dependent: :destroy\n \n   accepts_nested_attributes_for :answers, allow_destroy: true\n+  scope :search_word, ->search{where(Settings.sql_search, \"%#{search}%\")}\n+  scope :recent, ->{order Settings.sql_recent}\n+  scope :filter_category, ->category{where category_id: category if category.present?}\n+  scope :learned, ->user{where(Settings.sql_learned, user.id)}","path":"app/models/word.rb","position":7,"original_position":7,"commit_id":"10d0eb10d98ae1416fd01028641b242f4e9b9693","original_commit_id":"10d0eb10d98ae1416fd01028641b242f4e9b9693","user":{"login":"dieunb","id":2122175,"avatar_url":"https://avatars.githubusercontent.com/u/2122175?v=3","gravatar_id":"","url":"https://api.github.com/users/dieunb","html_url":"https://github.com/dieunb","followers_url":"https://api.github.com/users/dieunb/followers","following_url":"https://api.github.com/users/dieunb/following{/other_user}","gists_url":"https://api.github.com/users/dieunb/gists{/gist_id}","starred_url":"https://api.github.com/users/dieunb/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/dieunb/subscriptions","organizations_url":"https://api.github.com/users/dieunb/orgs","repos_url":"https://api.github.com/users/dieunb/repos","events_url":"https://api.github.com/users/dieunb/events{/privacy}","received_events_url":"https://api.github.com/users/dieunb/received_events","type":"User","site_admin":false},"body":"remove `()`","created_at":"2015-07-06T01:13:46Z","updated_at":"2015-07-06T01:13:46Z","html_url":"https://github.com/framgia/fels_66/pull/14#discussion_r33901509","pull_request_url":"https://api.github.com/repos/framgia/fels_66/pulls/14","_links":{"self":{"href":"https://api.github.com/repos/framgia/fels_66/pulls/comments/33901509"},"html":{"href":"https://github.com/framgia/fels_66/pull/14#discussion_r33901509"},"pull_request":{"href":"https://api.github.com/repos/framgia/fels_66/pulls/14"}}},"pull_request":{"url":"https://api.github.com/repos/framgia/fels_66/pulls/14","id":39142436,"html_url":"https://github.com/framgia/fels_66/pull/14","diff_url":"https://github.com/framgia/fels_66/pull/14.diff","patch_url":"https://github.com/framgia/fels_66/pull/14.patch","issue_url":"https://api.github.com/repos/framgia/fels_66/issues/14","number":14,"state":"open","locked":false,"title":"Showing word list","user":{"login":"ttuan","id":10399018,"avatar_url":"https://avatars.githubusercontent.com/u/10399018?v=3","gravatar_id":"","url":"https://api.github.com/users/ttuan","html_url":"https://github.com/ttuan","followers_url":"https://api.github.com/users/ttuan/followers","following_url":"https://api.github.com/users/ttuan/following{/other_user}","gists_url":"https://api.github.com/users/ttuan/gists{/gist_id}","starred_url":"https://api.github.com/users/ttuan/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/ttuan/subscriptions","organizations_url":"https://api.github.com/users/ttuan/orgs","repos_url":"https://api.github.com/users/ttuan/repos","events_url":"https://api.github.com/users/ttuan/events{/privacy}","received_events_url":"https://api.github.com/users/ttuan/received_events","type":"User","site_admin":false},"body":"","created_at":"2015-07-03T02:52:51Z","updated_at":"2015-07-06T01:13:46Z","closed_at":null,"merged_at":null,"merge_commit_sha":"ee3f25a2d45e46a8e9a3d243f3145f7dedfd4a30","assignee":null,"milestone":null,"commits_url":"https://api.github.com/repos/framgia/fels_66/pulls/14/commits","review_comments_url":"https://api.github.com/repos/framgia/fels_66/pulls/14/comments","review_comment_url":"https://api.github.com/repos/framgia/fels_66/pulls/comments{/number}","comments_url":"https://api.github.com/repos/framgia/fels_66/issues/14/comments","statuses_url":"https://api.github.com/repos/framgia/fels_66/statuses/10d0eb10d98ae1416fd01028641b242f4e9b9693","head":{"label":"ttuan:showing-word-list","ref":"showing-word-list","sha":"10d0eb10d98ae1416fd01028641b242f4e9b9693","user":{"login":"ttuan","id":10399018,"avatar_url":"https://avatars.githubusercontent.com/u/10399018?v=3","gravatar_id":"","url":"https://api.github.com/users/ttuan","html_url":"https://github.com/ttuan","followers_url":"https://api.github.com/users/ttuan/followers","following_url":"https://api.github.com/users/ttuan/following{/other_user}","gists_url":"https://api.github.com/users/ttuan/gists{/gist_id}","starred_url":"https://api.github.com/users/ttuan/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/ttuan/subscriptions","organizations_url":"https://api.github.com/users/ttuan/orgs","repos_url":"https://api.github.com/users/ttuan/repos","events_url":"https://api.github.com/users/ttuan/events{/privacy}","received_events_url":"https://api.github.com/users/ttuan/received_events","type":"User","site_admin":false},"repo":{"id":38035558,"name":"fels_66","full_name":"ttuan/fels_66","owner":{"login":"ttuan","id":10399018,"avatar_url":"https://avatars.githubusercontent.com/u/10399018?v=3","gravatar_id":"","url":"https://api.github.com/users/ttuan","html_url":"https://github.com/ttuan","followers_url":"https://api.github.com/users/ttuan/followers","following_url":"https://api.github.com/users/ttuan/following{/other_user}","gists_url":"https://api.github.com/users/ttuan/gists{/gist_id}","starred_url":"https://api.github.com/users/ttuan/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/ttuan/subscriptions","organizations_url":"https://api.github.com/users/ttuan/orgs","repos_url":"https://api.github.com/users/ttuan/repos","events_url":"https://api.github.com/users/ttuan/events{/privacy}","received_events_url":"https://api.github.com/users/ttuan/received_events","type":"User","site_admin":false},"private":false,"html_url":"https://github.com/ttuan/fels_66","description":"Framgia E-Learning System (training)","fork":true,"url":"https://api.github.com/repos/ttuan/fels_66","forks_url":"https://api.github.com/repos/ttuan/fels_66/forks","keys_url":"https://api.github.com/repos/ttuan/fels_66/keys{/key_id}","collaborators_url":"https://api.github.com/repos/ttuan/fels_66/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/ttuan/fels_66/teams","hooks_url":"https://api.github.com/repos/ttuan/fels_66/hooks","issue_events_url":"https://api.github.com/repos/ttuan/fels_66/issues/events{/number}","events_url":"https://api.github.com/repos/ttuan/fels_66/events","assignees_url":"https://api.github.com/repos/ttuan/fels_66/assignees{/user}","branches_url":"https://api.github.com/repos/ttuan/fels_66/branches{/branch}","tags_url":"https://api.github.com/repos/ttuan/fels_66/tags","blobs_url":"https://api.github.com/repos/ttuan/fels_66/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/ttuan/fels_66/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/ttuan/fels_66/git/refs{/sha}","trees_url":"https://api.github.com/repos/ttuan/fels_66/git/trees{/sha}","statuses_url":"https://api.github.com/repos/ttuan/fels_66/statuses/{sha}","languages_url":"https://api.github.com/repos/ttuan/fels_66/languages","stargazers_url":"https://api.github.com/repos/ttuan/fels_66/stargazers","contributors_url":"https://api.github.com/repos/ttuan/fels_66/contributors","subscribers_url":"https://api.github.com/repos/ttuan/fels_66/subscribers","subscription_url":"https://api.github.com/repos/ttuan/fels_66/subscription","commits_url":"https://api.github.com/repos/ttuan/fels_66/commits{/sha}","git_commits_url":"https://api.github.com/repos/ttuan/fels_66/git/commits{/sha}","comments_url":"https://api.github.com/repos/ttuan/fels_66/comments{/number}","issue_comment_url":"https://api.github.com/repos/ttuan/fels_66/issues/comments{/number}","contents_url":"https://api.github.com/repos/ttuan/fels_66/contents/{+path}","compare_url":"https://api.github.com/repos/ttuan/fels_66/compare/{base}...{head}","merges_url":"https://api.github.com/repos/ttuan/fels_66/merges","archive_url":"https://api.github.com/repos/ttuan/fels_66/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/ttuan/fels_66/downloads","issues_url":"https://api.github.com/repos/ttuan/fels_66/issues{/number}","pulls_url":"https://api.github.com/repos/ttuan/fels_66/pulls{/number}","milestones_url":"https://api.github.com/repos/ttuan/fels_66/milestones{/number}","notifications_url":"https://api.github.com/repos/ttuan/fels_66/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/ttuan/fels_66/labels{/name}","releases_url":"https://api.github.com/repos/ttuan/fels_66/releases{/id}","created_at":"2015-06-25T07:45:38Z","updated_at":"2015-06-25T02:12:42Z","pushed_at":"2015-07-05T14:34:53Z","git_url":"git://github.com/ttuan/fels_66.git","ssh_url":"git@github.com:ttuan/fels_66.git","clone_url":"https://github.com/ttuan/fels_66.git","svn_url":"https://github.com/ttuan/fels_66","homepage":null,"size":194,"stargazers_count":0,"watchers_count":0,"language":null,"has_issues":false,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":0,"mirror_url":null,"open_issues_count":0,"forks":0,"open_issues":0,"watchers":0,"default_branch":"master"}},"base":{"label":"framgia:develop","ref":"develop","sha":"fe5d8933070769e0696d720f0e243f19a6241636","user":{"login":"framgia","id":2322183,"avatar_url":"https://avatars.githubusercontent.com/u/2322183?v=3","gravatar_id":"","url":"https://api.github.com/users/framgia","html_url":"https://github.com/framgia","followers_url":"https://api.github.com/users/framgia/followers","following_url":"https://api.github.com/users/framgia/following{/other_user}","gists_url":"https://api.github.com/users/framgia/gists{/gist_id}","starred_url":"https://api.github.com/users/framgia/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/framgia/subscriptions","organizations_url":"https://api.github.com/users/framgia/orgs","repos_url":"https://api.github.com/users/framgia/repos","events_url":"https://api.github.com/users/framgia/events{/privacy}","received_events_url":"https://api.github.com/users/framgia/received_events","type":"Organization","site_admin":false},"repo":{"id":38022560,"name":"fels_66","full_name":"framgia/fels_66","owner":{"login":"framgia","id":2322183,"avatar_url":"https://avatars.githubusercontent.com/u/2322183?v=3","gravatar_id":"","url":"https://api.github.com/users/framgia","html_url":"https://github.com/framgia","followers_url":"https://api.github.com/users/framgia/followers","following_url":"https://api.github.com/users/framgia/following{/other_user}","gists_url":"https://api.github.com/users/framgia/gists{/gist_id}","starred_url":"https://api.github.com/users/framgia/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/framgia/subscriptions","organizations_url":"https://api.github.com/users/framgia/orgs","repos_url":"https://api.github.com/users/framgia/repos","events_url":"https://api.github.com/users/framgia/events{/privacy}","received_events_url":"https://api.github.com/users/framgia/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/framgia/fels_66","description":"Framgia E-Learning System (training)","fork":false,"url":"https://api.github.com/repos/framgia/fels_66","forks_url":"https://api.github.com/repos/framgia/fels_66/forks","keys_url":"https://api.github.com/repos/framgia/fels_66/keys{/key_id}","collaborators_url":"https://api.github.com/repos/framgia/fels_66/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/framgia/fels_66/teams","hooks_url":"https://api.github.com/repos/framgia/fels_66/hooks","issue_events_url":"https://api.github.com/repos/framgia/fels_66/issues/events{/number}","events_url":"https://api.github.com/repos/framgia/fels_66/events","assignees_url":"https://api.github.com/repos/framgia/fels_66/assignees{/user}","branches_url":"https://api.github.com/repos/framgia/fels_66/branches{/branch}","tags_url":"https://api.github.com/repos/framgia/fels_66/tags","blobs_url":"https://api.github.com/repos/framgia/fels_66/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/framgia/fels_66/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/framgia/fels_66/git/refs{/sha}","trees_url":"https://api.github.com/repos/framgia/fels_66/git/trees{/sha}","statuses_url":"https://api.github.com/repos/framgia/fels_66/statuses/{sha}","languages_url":"https://api.github.com/repos/framgia/fels_66/languages","stargazers_url":"https://api.github.com/repos/framgia/fels_66/stargazers","contributors_url":"https://api.github.com/repos/framgia/fels_66/contributors","subscribers_url":"https://api.github.com/repos/framgia/fels_66/subscribers","subscription_url":"https://api.github.com/repos/framgia/fels_66/subscription","commits_url":"https://api.github.com/repos/framgia/fels_66/commits{/sha}","git_commits_url":"https://api.github.com/repos/framgia/fels_66/git/commits{/sha}","comments_url":"https://api.github.com/repos/framgia/fels_66/comments{/number}","issue_comment_url":"https://api.github.com/repos/framgia/fels_66/issues/comments{/number}","contents_url":"https://api.github.com/repos/framgia/fels_66/contents/{+path}","compare_url":"https://api.github.com/repos/framgia/fels_66/compare/{base}...{head}","merges_url":"https://api.github.com/repos/framgia/fels_66/merges","archive_url":"https://api.github.com/repos/framgia/fels_66/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/framgia/fels_66/downloads","issues_url":"https://api.github.com/repos/framgia/fels_66/issues{/number}","pulls_url":"https://api.github.com/repos/framgia/fels_66/pulls{/number}","milestones_url":"https://api.github.com/repos/framgia/fels_66/milestones{/number}","notifications_url":"https://api.github.com/repos/framgia/fels_66/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/framgia/fels_66/labels{/name}","releases_url":"https://api.github.com/repos/framgia/fels_66/releases{/id}","created_at":"2015-06-25T02:12:42Z","updated_at":"2015-06-25T02:12:42Z","pushed_at":"2015-07-05T14:34:53Z","git_url":"git://github.com/framgia/fels_66.git","ssh_url":"git@github.com:framgia/fels_66.git","clone_url":"https://github.com/framgia/fels_66.git","svn_url":"https://github.com/framgia/fels_66","homepage":null,"size":357,"stargazers_count":0,"watchers_count":0,"language":null,"has_issues":true,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":2,"mirror_url":null,"open_issues_count":2,"forks":2,"open_issues":2,"watchers":0,"default_branch":"master"}},"_links":{"self":{"href":"https://api.github.com/repos/framgia/fels_66/pulls/14"},"html":{"href":"https://github.com/framgia/fels_66/pull/14"},"issue":{"href":"https://api.github.com/repos/framgia/fels_66/issues/14"},"comments":{"href":"https://api.github.com/repos/framgia/fels_66/issues/14/comments"},"review_comments":{"href":"https://api.github.com/repos/framgia/fels_66/pulls/14/comments"},"review_comment":{"href":"https://api.github.com/repos/framgia/fels_66/pulls/comments{/number}"},"commits":{"href":"https://api.github.com/repos/framgia/fels_66/pulls/14/commits"},"statuses":{"href":"https://api.github.com/repos/framgia/fels_66/statuses/10d0eb10d98ae1416fd01028641b242f4e9b9693"}}}}