{"action":"created","issue":{"url":"https://api.github.com/repos/scambra/devise_invitable/issues/334","labels_url":"https://api.github.com/repos/scambra/devise_invitable/issues/334/labels{/name}","comments_url":"https://api.github.com/repos/scambra/devise_invitable/issues/334/comments","events_url":"https://api.github.com/repos/scambra/devise_invitable/issues/334/events","html_url":"https://github.com/scambra/devise_invitable/issues/334","id":16961738,"number":334,"title":"Unpermitted params","user":{"login":"pawel2105","id":811477,"avatar_url":"https://avatars.githubusercontent.com/u/811477?v=3","gravatar_id":"","url":"https://api.github.com/users/pawel2105","html_url":"https://github.com/pawel2105","followers_url":"https://api.github.com/users/pawel2105/followers","following_url":"https://api.github.com/users/pawel2105/following{/other_user}","gists_url":"https://api.github.com/users/pawel2105/gists{/gist_id}","starred_url":"https://api.github.com/users/pawel2105/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/pawel2105/subscriptions","organizations_url":"https://api.github.com/users/pawel2105/orgs","repos_url":"https://api.github.com/users/pawel2105/repos","events_url":"https://api.github.com/users/pawel2105/events{/privacy}","received_events_url":"https://api.github.com/users/pawel2105/received_events","type":"User","site_admin":false},"labels":[],"state":"closed","locked":false,"assignee":null,"milestone":null,"comments":10,"created_at":"2013-07-19T08:47:17Z","updated_at":"2016-01-22T13:05:15Z","closed_at":"2013-07-22T16:55:50Z","body":"Hi\r\n\r\nI have added an initializer as per [this page](https://github.com/scambra/devise_invitable/wiki/Devise-Invitable-With-Strong-Parameters-Gem).\r\n\r\n    Devise::InvitationsController.class_eval do\r\n      def resource_params\r\n        params.require(resource_name).permit(\r\n          :invitation_token,\r\n          :password,\r\n          :password_confirmation,\r\n          :name,\r\n          :email,\r\n          :invitation_token,\r\n          :nickname,\r\n          :location,\r\n          :position,\r\n          :phone\r\n        )\r\n      end\r\n    end\r\n\r\nMy Gemfile has: `gem 'devise_invitable', branch: 'rails4', :git => 'git://github.com/scambra/devise_invitable.git'` which is at `1c6a50bb2`. I'm also using Rails 4.1.0 beta and Devise 3.0.0\r\n\r\nWhen filling in the accept invitation form I've added the above fields to the form in addition to the password fields and the log outputs:\r\n\r\n    Unpermitted parameters: name, email, nickname, location, position, phone"},"comment":{"url":"https://api.github.com/repos/scambra/devise_invitable/issues/comments/173915530","html_url":"https://github.com/scambra/devise_invitable/issues/334#issuecomment-173915530","issue_url":"https://api.github.com/repos/scambra/devise_invitable/issues/334","id":173915530,"user":{"login":"Extazystas","id":2153311,"avatar_url":"https://avatars.githubusercontent.com/u/2153311?v=3","gravatar_id":"","url":"https://api.github.com/users/Extazystas","html_url":"https://github.com/Extazystas","followers_url":"https://api.github.com/users/Extazystas/followers","following_url":"https://api.github.com/users/Extazystas/following{/other_user}","gists_url":"https://api.github.com/users/Extazystas/gists{/gist_id}","starred_url":"https://api.github.com/users/Extazystas/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/Extazystas/subscriptions","organizations_url":"https://api.github.com/users/Extazystas/orgs","repos_url":"https://api.github.com/users/Extazystas/repos","events_url":"https://api.github.com/users/Extazystas/events{/privacy}","received_events_url":"https://api.github.com/users/Extazystas/received_events","type":"User","site_admin":false},"created_at":"2016-01-22T13:05:15Z","updated_at":"2016-01-22T13:05:15Z","body":"Have the same issue, above solutions are not working for me. So I did a little monkey patching in devise module:\r\n\r\n```\r\nmodule DeviseInvitable\r\n  module ParameterSanitizer\r\n    custom_fields_list = [:custom_field1, :custom_field2]\r\n    private\r\n\r\n    if defined?(Devise::BaseSanitizer)\r\n      def permit(keys)\r\n        default_params.permit(*Array(keys))\r\n      end\r\n\r\n      def attributes_for_with_invitable(kind)\r\n        case kind\r\n        when :invite\r\n          resource_class.respond_to?(:invite_key_fields) ? resource_class.invite_key_fields.concat(custom_fields_list) : []\r\n        when :accept_invitation\r\n          [:password, :password_confirmation, :invitation_token]\r\n        else attributes_for_without_invitable(kind)\r\n        end\r\n      end\r\n    else\r\n      def initialize_with_invitable(resource_class, resource_name, params)\r\n        initialize_without_invitable(resource_class, resource_name, params)\r\n        permit(:invite, keys: (resource_class.respond_to?(:invite_key_fields) ? resource_class.invite_key_fields.concat(custom_fields_list) : []) )\r\n        permit(:accept_invitation, keys: [:password, :password_confirmation, :invitation_token] )\r\n      end\r\n    end\r\n  end\r\nend\r\n``` \r\nJust place it to initializers."}}