{"action":"created","comment":{"url":"https://api.github.com/repos/beauties-beast/barker-secudev/pulls/comments/39303373","id":39303373,"diff_hunk":"@@ -19,4 +11,84 @@\n   salt: salt,\n   aboutme: \"I'm good at singing and managing systems. How about you?\"\n }\n-User.create(options)\n+puts \"Creating user admin.\" \n+admin = User.create(options)\n+\n+firstnames = [\"Boggs\", \"Deanne\", \"Via\"]\n+lastnames = [\"Aldanese\", \"Chan\", \"Sido\"]\n+genders = [\"Male\", \"Female\", \"Female\"]\n+salutations = [\"Mr.\", \"Ms.\", \"Ms.\"]\n+birthdates = [Date.parse(\"July 30, 1995\"), Date.parse(\"October 19, 1995\"), Date.parse(\"June 7, 1995\")]\n+usernames = [\"boggs\", \"deanne\", \"via\"]\n+aboutmes = [\"I am Boggs.\", \"I am Deanne.\", \"I am Via.\"]\n+\n+firstnames.each_with_index { |x, i|\n+  salt = User.generate_salt\n+  puts \"Creating user #{usernames[i]}.\"\n+  options = {\n+    accesslevel: \"user\",\n+    firstname: firstnames[i],\n+    lastname: lastnames[i],\n+    gender: genders[i],\n+    salutation: salutations[i],\n+    birthdate: birthdates[i],\n+    username: usernames[i],\n+    password: User.hash_password(\"password\", salt),\n+    passwordverify: User.hash_password(\"password\", salt),\n+    salt: salt,\n+    aboutme: aboutmes[i]\n+  }\n+  resp = User.new_user(options, admin)\n+  if resp[:errors]\n+    puts resp[:errors]\n+  elsif resp[:messages]\n+    puts resp[:messages]\n+  end\n+}\n+\n+posts_max = 100\n+posts_interval = 1.day\n+post_contents = [\n+  \"[b]Bold[/b]\", \n+  \"[i]Italic[/i]\", \n+  \"[u]Underline[/u]\"\n+]\n+post_users = [\n+  User.find_by_username(\"boggs\"),\n+  User.find_by_username(\"deanne\"),\n+  User.find_by_username(\"via\")\n+]\n+\n+for x in 1..posts_max","path":"db/seeds.rb","position":65,"original_position":65,"commit_id":"b71a105bfe3f60a76d75495630a05b32e3ac2562","original_commit_id":"b71a105bfe3f60a76d75495630a05b32e3ac2562","user":{"login":"houndci","id":6697940,"avatar_url":"https://avatars.githubusercontent.com/u/6697940?v=3","gravatar_id":"","url":"https://api.github.com/users/houndci","html_url":"https://github.com/houndci","followers_url":"https://api.github.com/users/houndci/followers","following_url":"https://api.github.com/users/houndci/following{/other_user}","gists_url":"https://api.github.com/users/houndci/gists{/gist_id}","starred_url":"https://api.github.com/users/houndci/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/houndci/subscriptions","organizations_url":"https://api.github.com/users/houndci/orgs","repos_url":"https://api.github.com/users/houndci/repos","events_url":"https://api.github.com/users/houndci/events{/privacy}","received_events_url":"https://api.github.com/users/houndci/received_events","type":"User","site_admin":false},"body":"Prefer `each` over `for`.","created_at":"2015-09-11T18:43:48Z","updated_at":"2015-09-11T18:43:48Z","html_url":"https://github.com/beauties-beast/barker-secudev/pull/7#discussion_r39303373","pull_request_url":"https://api.github.com/repos/beauties-beast/barker-secudev/pulls/7","_links":{"self":{"href":"https://api.github.com/repos/beauties-beast/barker-secudev/pulls/comments/39303373"},"html":{"href":"https://github.com/beauties-beast/barker-secudev/pull/7#discussion_r39303373"},"pull_request":{"href":"https://api.github.com/repos/beauties-beast/barker-secudev/pulls/7"}}},"pull_request":{"url":"https://api.github.com/repos/beauties-beast/barker-secudev/pulls/7","id":44815422,"html_url":"https://github.com/beauties-beast/barker-secudev/pull/7","diff_url":"https://github.com/beauties-beast/barker-secudev/pull/7.diff","patch_url":"https://github.com/beauties-beast/barker-secudev/pull/7.patch","issue_url":"https://api.github.com/repos/beauties-beast/barker-secudev/issues/7","number":7,"state":"open","locked":false,"title":"Global message boards","user":{"login":"b-ggs","id":6130147,"avatar_url":"https://avatars.githubusercontent.com/u/6130147?v=3","gravatar_id":"","url":"https://api.github.com/users/b-ggs","html_url":"https://github.com/b-ggs","followers_url":"https://api.github.com/users/b-ggs/followers","following_url":"https://api.github.com/users/b-ggs/following{/other_user}","gists_url":"https://api.github.com/users/b-ggs/gists{/gist_id}","starred_url":"https://api.github.com/users/b-ggs/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/b-ggs/subscriptions","organizations_url":"https://api.github.com/users/b-ggs/orgs","repos_url":"https://api.github.com/users/b-ggs/repos","events_url":"https://api.github.com/users/b-ggs/events{/privacy}","received_events_url":"https://api.github.com/users/b-ggs/received_events","type":"User","site_admin":false},"body":"For this part of the SECUDEV Case 2 specs:\r\n\r\nGlobal Message Boards – Messages\r\nBelow the profile information in the public landing page\r\nShow a paginated table with at most 10 entries sort by the last post date of the user\r\nEach row should be like:\r\n<<First Name>>\r\n<<Username>>\r\n<<Date Joined>>\r\n<<Date Posted>>                                       Edit   Delete\r\n<<POST>>\r\n<<Edited Date if edited>>\r\n<<First Name>> and the <<Username>> must be clickable and would go to separate a page that shows the user’s profile information similar to the information displayed in the login landing page\r\nThe links Edit and Delete should only show up if the current logged in user is the owner of the post of if he is an admin","created_at":"2015-09-11T18:43:36Z","updated_at":"2015-09-11T18:43:49Z","closed_at":null,"merged_at":null,"merge_commit_sha":null,"assignee":null,"milestone":null,"commits_url":"https://api.github.com/repos/beauties-beast/barker-secudev/pulls/7/commits","review_comments_url":"https://api.github.com/repos/beauties-beast/barker-secudev/pulls/7/comments","review_comment_url":"https://api.github.com/repos/beauties-beast/barker-secudev/pulls/comments{/number}","comments_url":"https://api.github.com/repos/beauties-beast/barker-secudev/issues/7/comments","statuses_url":"https://api.github.com/repos/beauties-beast/barker-secudev/statuses/b71a105bfe3f60a76d75495630a05b32e3ac2562","head":{"label":"beauties-beast:global-message-boards","ref":"global-message-boards","sha":"b71a105bfe3f60a76d75495630a05b32e3ac2562","user":{"login":"beauties-beast","id":13806071,"avatar_url":"https://avatars.githubusercontent.com/u/13806071?v=3","gravatar_id":"","url":"https://api.github.com/users/beauties-beast","html_url":"https://github.com/beauties-beast","followers_url":"https://api.github.com/users/beauties-beast/followers","following_url":"https://api.github.com/users/beauties-beast/following{/other_user}","gists_url":"https://api.github.com/users/beauties-beast/gists{/gist_id}","starred_url":"https://api.github.com/users/beauties-beast/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/beauties-beast/subscriptions","organizations_url":"https://api.github.com/users/beauties-beast/orgs","repos_url":"https://api.github.com/users/beauties-beast/repos","events_url":"https://api.github.com/users/beauties-beast/events{/privacy}","received_events_url":"https://api.github.com/users/beauties-beast/received_events","type":"Organization","site_admin":false},"repo":{"id":41613810,"name":"barker-secudev","full_name":"beauties-beast/barker-secudev","owner":{"login":"beauties-beast","id":13806071,"avatar_url":"https://avatars.githubusercontent.com/u/13806071?v=3","gravatar_id":"","url":"https://api.github.com/users/beauties-beast","html_url":"https://github.com/beauties-beast","followers_url":"https://api.github.com/users/beauties-beast/followers","following_url":"https://api.github.com/users/beauties-beast/following{/other_user}","gists_url":"https://api.github.com/users/beauties-beast/gists{/gist_id}","starred_url":"https://api.github.com/users/beauties-beast/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/beauties-beast/subscriptions","organizations_url":"https://api.github.com/users/beauties-beast/orgs","repos_url":"https://api.github.com/users/beauties-beast/repos","events_url":"https://api.github.com/users/beauties-beast/events{/privacy}","received_events_url":"https://api.github.com/users/beauties-beast/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/beauties-beast/barker-secudev","description":"Barker is a Twitter-like Rails app made for Secure Development under Mr. Solomon See.","fork":false,"url":"https://api.github.com/repos/beauties-beast/barker-secudev","forks_url":"https://api.github.com/repos/beauties-beast/barker-secudev/forks","keys_url":"https://api.github.com/repos/beauties-beast/barker-secudev/keys{/key_id}","collaborators_url":"https://api.github.com/repos/beauties-beast/barker-secudev/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/beauties-beast/barker-secudev/teams","hooks_url":"https://api.github.com/repos/beauties-beast/barker-secudev/hooks","issue_events_url":"https://api.github.com/repos/beauties-beast/barker-secudev/issues/events{/number}","events_url":"https://api.github.com/repos/beauties-beast/barker-secudev/events","assignees_url":"https://api.github.com/repos/beauties-beast/barker-secudev/assignees{/user}","branches_url":"https://api.github.com/repos/beauties-beast/barker-secudev/branches{/branch}","tags_url":"https://api.github.com/repos/beauties-beast/barker-secudev/tags","blobs_url":"https://api.github.com/repos/beauties-beast/barker-secudev/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/beauties-beast/barker-secudev/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/beauties-beast/barker-secudev/git/refs{/sha}","trees_url":"https://api.github.com/repos/beauties-beast/barker-secudev/git/trees{/sha}","statuses_url":"https://api.github.com/repos/beauties-beast/barker-secudev/statuses/{sha}","languages_url":"https://api.github.com/repos/beauties-beast/barker-secudev/languages","stargazers_url":"https://api.github.com/repos/beauties-beast/barker-secudev/stargazers","contributors_url":"https://api.github.com/repos/beauties-beast/barker-secudev/contributors","subscribers_url":"https://api.github.com/repos/beauties-beast/barker-secudev/subscribers","subscription_url":"https://api.github.com/repos/beauties-beast/barker-secudev/subscription","commits_url":"https://api.github.com/repos/beauties-beast/barker-secudev/commits{/sha}","git_commits_url":"https://api.github.com/repos/beauties-beast/barker-secudev/git/commits{/sha}","comments_url":"https://api.github.com/repos/beauties-beast/barker-secudev/comments{/number}","issue_comment_url":"https://api.github.com/repos/beauties-beast/barker-secudev/issues/comments{/number}","contents_url":"https://api.github.com/repos/beauties-beast/barker-secudev/contents/{+path}","compare_url":"https://api.github.com/repos/beauties-beast/barker-secudev/compare/{base}...{head}","merges_url":"https://api.github.com/repos/beauties-beast/barker-secudev/merges","archive_url":"https://api.github.com/repos/beauties-beast/barker-secudev/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/beauties-beast/barker-secudev/downloads","issues_url":"https://api.github.com/repos/beauties-beast/barker-secudev/issues{/number}","pulls_url":"https://api.github.com/repos/beauties-beast/barker-secudev/pulls{/number}","milestones_url":"https://api.github.com/repos/beauties-beast/barker-secudev/milestones{/number}","notifications_url":"https://api.github.com/repos/beauties-beast/barker-secudev/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/beauties-beast/barker-secudev/labels{/name}","releases_url":"https://api.github.com/repos/beauties-beast/barker-secudev/releases{/id}","created_at":"2015-08-30T02:15:41Z","updated_at":"2015-09-09T14:48:09Z","pushed_at":"2015-09-11T18:43:37Z","git_url":"git://github.com/beauties-beast/barker-secudev.git","ssh_url":"git@github.com:beauties-beast/barker-secudev.git","clone_url":"https://github.com/beauties-beast/barker-secudev.git","svn_url":"https://github.com/beauties-beast/barker-secudev","homepage":"","size":360,"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":"beauties-beast:master","ref":"master","sha":"a4cdcb24d6cdd337674d9e0f483109a31fcf2297","user":{"login":"beauties-beast","id":13806071,"avatar_url":"https://avatars.githubusercontent.com/u/13806071?v=3","gravatar_id":"","url":"https://api.github.com/users/beauties-beast","html_url":"https://github.com/beauties-beast","followers_url":"https://api.github.com/users/beauties-beast/followers","following_url":"https://api.github.com/users/beauties-beast/following{/other_user}","gists_url":"https://api.github.com/users/beauties-beast/gists{/gist_id}","starred_url":"https://api.github.com/users/beauties-beast/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/beauties-beast/subscriptions","organizations_url":"https://api.github.com/users/beauties-beast/orgs","repos_url":"https://api.github.com/users/beauties-beast/repos","events_url":"https://api.github.com/users/beauties-beast/events{/privacy}","received_events_url":"https://api.github.com/users/beauties-beast/received_events","type":"Organization","site_admin":false},"repo":{"id":41613810,"name":"barker-secudev","full_name":"beauties-beast/barker-secudev","owner":{"login":"beauties-beast","id":13806071,"avatar_url":"https://avatars.githubusercontent.com/u/13806071?v=3","gravatar_id":"","url":"https://api.github.com/users/beauties-beast","html_url":"https://github.com/beauties-beast","followers_url":"https://api.github.com/users/beauties-beast/followers","following_url":"https://api.github.com/users/beauties-beast/following{/other_user}","gists_url":"https://api.github.com/users/beauties-beast/gists{/gist_id}","starred_url":"https://api.github.com/users/beauties-beast/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/beauties-beast/subscriptions","organizations_url":"https://api.github.com/users/beauties-beast/orgs","repos_url":"https://api.github.com/users/beauties-beast/repos","events_url":"https://api.github.com/users/beauties-beast/events{/privacy}","received_events_url":"https://api.github.com/users/beauties-beast/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/beauties-beast/barker-secudev","description":"Barker is a Twitter-like Rails app made for Secure Development under Mr. Solomon See.","fork":false,"url":"https://api.github.com/repos/beauties-beast/barker-secudev","forks_url":"https://api.github.com/repos/beauties-beast/barker-secudev/forks","keys_url":"https://api.github.com/repos/beauties-beast/barker-secudev/keys{/key_id}","collaborators_url":"https://api.github.com/repos/beauties-beast/barker-secudev/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/beauties-beast/barker-secudev/teams","hooks_url":"https://api.github.com/repos/beauties-beast/barker-secudev/hooks","issue_events_url":"https://api.github.com/repos/beauties-beast/barker-secudev/issues/events{/number}","events_url":"https://api.github.com/repos/beauties-beast/barker-secudev/events","assignees_url":"https://api.github.com/repos/beauties-beast/barker-secudev/assignees{/user}","branches_url":"https://api.github.com/repos/beauties-beast/barker-secudev/branches{/branch}","tags_url":"https://api.github.com/repos/beauties-beast/barker-secudev/tags","blobs_url":"https://api.github.com/repos/beauties-beast/barker-secudev/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/beauties-beast/barker-secudev/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/beauties-beast/barker-secudev/git/refs{/sha}","trees_url":"https://api.github.com/repos/beauties-beast/barker-secudev/git/trees{/sha}","statuses_url":"https://api.github.com/repos/beauties-beast/barker-secudev/statuses/{sha}","languages_url":"https://api.github.com/repos/beauties-beast/barker-secudev/languages","stargazers_url":"https://api.github.com/repos/beauties-beast/barker-secudev/stargazers","contributors_url":"https://api.github.com/repos/beauties-beast/barker-secudev/contributors","subscribers_url":"https://api.github.com/repos/beauties-beast/barker-secudev/subscribers","subscription_url":"https://api.github.com/repos/beauties-beast/barker-secudev/subscription","commits_url":"https://api.github.com/repos/beauties-beast/barker-secudev/commits{/sha}","git_commits_url":"https://api.github.com/repos/beauties-beast/barker-secudev/git/commits{/sha}","comments_url":"https://api.github.com/repos/beauties-beast/barker-secudev/comments{/number}","issue_comment_url":"https://api.github.com/repos/beauties-beast/barker-secudev/issues/comments{/number}","contents_url":"https://api.github.com/repos/beauties-beast/barker-secudev/contents/{+path}","compare_url":"https://api.github.com/repos/beauties-beast/barker-secudev/compare/{base}...{head}","merges_url":"https://api.github.com/repos/beauties-beast/barker-secudev/merges","archive_url":"https://api.github.com/repos/beauties-beast/barker-secudev/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/beauties-beast/barker-secudev/downloads","issues_url":"https://api.github.com/repos/beauties-beast/barker-secudev/issues{/number}","pulls_url":"https://api.github.com/repos/beauties-beast/barker-secudev/pulls{/number}","milestones_url":"https://api.github.com/repos/beauties-beast/barker-secudev/milestones{/number}","notifications_url":"https://api.github.com/repos/beauties-beast/barker-secudev/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/beauties-beast/barker-secudev/labels{/name}","releases_url":"https://api.github.com/repos/beauties-beast/barker-secudev/releases{/id}","created_at":"2015-08-30T02:15:41Z","updated_at":"2015-09-09T14:48:09Z","pushed_at":"2015-09-11T18:43:37Z","git_url":"git://github.com/beauties-beast/barker-secudev.git","ssh_url":"git@github.com:beauties-beast/barker-secudev.git","clone_url":"https://github.com/beauties-beast/barker-secudev.git","svn_url":"https://github.com/beauties-beast/barker-secudev","homepage":"","size":360,"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/beauties-beast/barker-secudev/pulls/7"},"html":{"href":"https://github.com/beauties-beast/barker-secudev/pull/7"},"issue":{"href":"https://api.github.com/repos/beauties-beast/barker-secudev/issues/7"},"comments":{"href":"https://api.github.com/repos/beauties-beast/barker-secudev/issues/7/comments"},"review_comments":{"href":"https://api.github.com/repos/beauties-beast/barker-secudev/pulls/7/comments"},"review_comment":{"href":"https://api.github.com/repos/beauties-beast/barker-secudev/pulls/comments{/number}"},"commits":{"href":"https://api.github.com/repos/beauties-beast/barker-secudev/pulls/7/commits"},"statuses":{"href":"https://api.github.com/repos/beauties-beast/barker-secudev/statuses/b71a105bfe3f60a76d75495630a05b32e3ac2562"}}}}