README.md in devise_oam-0.0.2 vs README.md in devise_oam-0.0.3

- old
+ new

@@ -6,11 +6,11 @@ integration with Oracle Access Manager. ## Installation In **Rails 3**, add this to your Gemfile and run the `bundle` command. - gem "devise_oam", github: "whatthewhat/devise_oam" + gem "devise_oam", "~> 0.0.3" ## Usage 1) Add the `HeaderAuthenticatable` strategy in devise initializer `config/initializers/devise.rb`: ```ruby @@ -36,12 +36,15 @@ * `user_class` - class of your devise user model * `user_login_field` - login field for the user model (should be unique) * `create_user_if_not_found` - if set to true this will create a new user if no user was found * `create_user_method` - method in the `user_class` to handle new user creation * `ldap_header` - HTTP header for LDAP roles -* `roles_setter` - method in the `user_class` to handle updating user roles +* `update_user_method` - method in the `user_class` to handle updating user roles and additional attributes +* `attr_headers` - headers with additional attributes that are passed to `update_user_method` +`roles_setter` should still work, but is deprecated + ### Automatic user creation If you need to automatically create new users based on `oam_header` you need to do the following: 1. Set `create_user_if_not_found` setting to `true` 2. Add a method to your user class that will accept a hash of params (`user_login_field` and also `:roles` if you are using LDAP roles) and create a new user @@ -52,10 +55,10 @@ ### LDAP roles To use LDAP roles parsing: 1. Set `ldap_header` setting to the HTTP header with roles (should be a comma separated string) 2. Add a method to your user class that will accept an array with roles and update the user -3. In the initializer set `roles_setter` setting to the method you've just created +3. In the initializer set `update_user_method` setting to the method you've just created For an example see `test/dummy` app. ## Links * [Devise](https://github.com/plataformatec/devise) \ No newline at end of file