GitHub PullRequestReviewCommentEvent at 2014-04-25 15:52:08
Repository: Coolsoft-14
Actor: KhaledHelmy
Payload: {"comment":{"url":"https://api.github.com/repos/alaashafaee/Coolsoft-14/pulls/comments/12002590","id":12002590,"diff_hunk":"@@ -5,45 +5,70 @@ class ApplicationController < ActionController::Base\n \tbefore_action :authenticate!\n \tprotect_from_forgery with: :exception\n \tbefore_action :update_sanitized_params, if: :devise_controller?\n+\tbefore_action :check_resource, if: :devise_controller?\n \n-\t# [User Authentication Advanced - Story 5.9, 5.10, 5.11, 5.14, 5.15]\n-\t# Permits some fields to be passed through sign up forms to update the lecturer,\n-\t# \tstudent, and teaching_assistant models\n-\t# Parameters: None\n-\t# Returns: None\n-\t# Author: Khaled Helmy\n \tprivate\n-\tdef update_sanitized_params\n-\t\tif \"#{resource_name}\" == \"lecturer\"\n-\t\t\tdevise_parameter_sanitizer.for(:sign_up) {\n-\t\t\t\t|u| u.permit(:name, :email, :password, :password_confirmation, :gender, :dob, :degree, \n-\t\t\t\t\t:university, :department, :profile_image, :profile_image_cache)\n-\t\t\t}\n-\t\telsif \"#{resource_name}\" == \"student\"\n-\t\t\tdevise_parameter_sanitizer.for(:sign_up) {\n-\t\t\t\t|u| u.permit(:name, :email, :password, :password_confirmation, :gender, :dob, :university, \n-\t\t\t\t\t:faculty, :major, :semester, :advising, :probation, :profile_image, :profile_image_cache)\n-\t\t\t}\n-\t\telsif \"#{resource_name}\" == \"teaching_assistant\"\n-\t\t\tdevise_parameter_sanitizer.for(:sign_up) {\n-\t\t\t\t|u| u.permit(:name, :email, :password, :password_confirmation, :gender, :dob,\n-\t\t\t\t\t:graduated_from, :graduated_year, :degree, :university, :department, \n-\t\t\t\t\t:profile_image, :profile_image_cache)\n-\t\t\t}\n+\n+\t\t# [User Authentication Advanced - Story 5.9, 5.10, 5.11, 5.14, 5.15]\n+\t\t# Permits some fields to be passed through sign up forms to update the lecturer,\n+\t\t# \tstudent, and teaching_assistant models\n+\t\t# Parameters: None\n+\t\t# Returns: None\n+\t\t# Author: Khaled Helmy\n+\t\tdef update_sanitized_params\n+\t\t\tif \"#{resource_name}\" == \"lecturer\"\n+\t\t\t\tdevise_parameter_sanitizer.for(:sign_up) {\n+\t\t\t\t\t|u| u.permit(:name, :email, :password, :password_confirmation, :gender, :dob, :degree, ","path":"tutor/app/controllers/application_controller.rb","position":40,"original_position":40,"commit_id":"33478e94e44f921b44b25a84a3b1f7c50aaa9b9f","original_commit_id":"33478e94e44f921b44b25a84a3b1f7c50aaa9b9f","user":{"login":"KhaledHelmy","id":6735475,"avatar_url":"https://avatars.githubusercontent.com/u/6735475?","gravatar_id":"943e246417efffca9306d384685a807d","url":"https://api.github.com/users/KhaledHelmy","html_url":"https://github.com/KhaledHelmy","followers_url":"https://api.github.com/users/KhaledHelmy/followers","following_url":"https://api.github.com/users/KhaledHelmy/following{/other_user}","gists_url":"https://api.github.com/users/KhaledHelmy/gists{/gist_id}","starred_url":"https://api.github.com/users/KhaledHelmy/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/KhaledHelmy/subscriptions","organizations_url":"https://api.github.com/users/KhaledHelmy/orgs","repos_url":"https://api.github.com/users/KhaledHelmy/repos","events_url":"https://api.github.com/users/KhaledHelmy/events{/privacy}","received_events_url":"https://api.github.com/users/KhaledHelmy/received_events","type":"User","site_admin":false},"body":"@rami-khalil What is the thing that is not descriptive?","created_at":"2014-04-25T15:52:08Z","updated_at":"2014-04-25T15:52:08Z","html_url":"https://github.com/alaashafaee/Coolsoft-14/pull/381#discussion_r12002590","pull_request_url":"https://api.github.com/repos/alaashafaee/Coolsoft-14/pulls/381","_links":{"self":{"href":"https://api.github.com/repos/alaashafaee/Coolsoft-14/pulls/comments/12002590"},"html":{"href":"https://github.com/alaashafaee/Coolsoft-14/pull/381#discussion_r12002590"},"pull_request":{"href":"https://api.github.com/repos/alaashafaee/Coolsoft-14/pulls/381"}}}}