README.md in intercom-rails-0.3.5 vs README.md in intercom-rails-0.3.8

- old
+ new

@@ -2,10 +2,12 @@ The easiest way to install Intercom in a rails app. For interacting with the Intercom REST API, use the `intercom` gem (https://github.com/intercom/intercom-ruby) +Requires ruby 2.0 or higher for `intercom-rails >= 4.0` + ## Installation Add this to your Gemfile: ```ruby gem "intercom-rails" @@ -24,11 +26,11 @@ ``` To make installing Intercom easy, where possible a `<script>` tag **will be automatically inserted before the closing `</body>` tag**. For most Rails apps, **you won't need to do any extra config**. Having trouble? Check out troubleshooting below. -### Live Chat +### Live Chat With the Intercom Messenger you can [chat](https://www.intercom.com/live-chat) with users and visitors to your web site. Include the Intercom Messenger on every page by setting: ```ruby config.include_for_logged_out_users = true ``` @@ -58,11 +60,11 @@ Feel free to mail us: team@intercom.io, if you're still having trouble. ## Configuration ### API Secret -If you want to use secure mode, ensure you set your API secret in `config/initializers/intercom.rb`: +If you want to use Identity Verification, ensure you set your API secret in `config/initializers/intercom.rb`: ```ruby config.api_secret = '123456' ``` **Note: This example is just for the sake of simplicity, you should never include your api secret in source control. Instead, you should use the Rails [secret config](http://guides.rubyonrails.org/4_1_release_notes.html#config-secrets-yml) feature.** @@ -382,11 +384,12 @@ end class DeleteFromIntercom < ApplicationJob def perform(user) intercom = Intercom::Client.new - intercom.users.find(email: user.email).delete + user = intercom.users.find(id: user.id) + deleted_user = intercom.users.delete(user) end end ``` ## Running tests/specs @@ -414,10 +417,10 @@ multiple pull requests. - **Send coherent history**. Make sure each individual commit in your pull request is meaningful. If you had to make multiple intermediate commits while developing, please squash them before sending them to us. - + ## Contributors - Dr Nic Williams (@drnic) - provided a rails generator for adding the Intercom javascript tag into your layout. - Alexander Chaychuk (@sashich) - fixed bug in user detection when users not persisted (e.g. new session view with devise).