Skip to content
Browse files

Update README.md

  • Loading branch information...
1 parent a79e897 commit 37e4262e0bca9a1dd55a9d190631d9036b3ebd62 @unders committed
Showing with 8 additions and 6 deletions.
  1. +8 −6 README.md
View
14 README.md
@@ -13,12 +13,6 @@ for more info.
* see [spec](https://github.com/unders/trusted_keys/blob/master/spec/trusted_keys_spec.rb)
## Usage
-Add to Gemfile:
-
-``` ruby
-gem 'trusted_keys'
-```
-
Include it in your application controller:
``` ruby
@@ -41,8 +35,16 @@ The above commands reads like this: _trust the following attributes: 'title', ..
returned by the params[:event] hash_.
+Inside your action:
+``` ruby
+def create
+ @event = Event.create(trusted_attributes)
+ respond_with(@event)
+end
+```
+And it will only return the trusted attributes.
## Installation

0 comments on commit 37e4262

Please sign in to comment.
Something went wrong with that request. Please try again.