Skip to content

Commit 988e318

Browse files
committed
Update README to reflect #91 changes
1 parent 82772b6 commit 988e318

1 file changed

Lines changed: 4 additions & 12 deletions

File tree

README.md

Lines changed: 4 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -193,16 +193,12 @@ class User < ApplicationRecord
193193
:confirmable
194194

195195
# including after calling the `devise` method is important.
196-
# include DeviseTokenAuth::Concerns::User # is also valid (generator includes this one).
197196
include GraphqlDevise::Concerns::Model
198197
end
199198
```
200199

201200
The install generator can do this for you if you specify the `user_class` option.
202201
See [Installation](#installation) for details.
203-
The generator will include a different module in your model, `DeviseTokenAuth::Concerns::User` which is also correct,
204-
we just made an alias on our namespace for consistency and possible extension.
205-
Generators have to be updated to generate our module.
206202

207203
### Customizing Email Templates
208204
The approach of this gem is a bit different from DeviseTokenAuth. We have placed our templates in `app/views/graphql_devise/mailer`,
@@ -226,7 +222,6 @@ In our example our model is `User`, so it would look like this:
226222
# app/controllers/my_controller.rb
227223

228224
class MyController < ApplicationController
229-
# include DeviseTokenAuth::Concerns::SetUserByToken # is also valid (generator includes this one).
230225
include GraphqlDevise::Concerns::SetUserByToken
231226

232227
before_action :authenticate_user!
@@ -239,9 +234,6 @@ end
239234

240235
The install generator can do this for you because it executes DTA installer.
241236
See [Installation](#Installation) for details.
242-
The generator will include a different module in your model, `DeviseTokenAuth::Concerns::SetUserByToken` which is also correct,
243-
we just made an alias on our namespace for consistency and possible extension.
244-
Generators have to be updated to generate our module.
245237

246238
### Making Requests
247239
Here is a list of the available mutations and queries assuming your mounted model is `User`.
@@ -290,10 +282,10 @@ as comments. You can also use
290282
**[DTA's docs](https://devise-token-auth.gitbook.io/devise-token-auth/config/initialization)** as a reference.
291283
In this section the most important configurations will be highlighted.
292284

293-
- **change_headers_on_each_request:** This configurations defaults to `true`. This means that tokens will change on
294-
each request you make, and the new values will be returned in the headers. So your client needs to handle this.
295-
Setting this to `false` will allow you to store the credentials for as long as the token life_span permits. And
296-
you can send the same credentials in each request.
285+
- **change_headers_on_each_request:** This configurations defaults to `false`. This will allow you to store the
286+
credentials for as long as the token life_span permits. And you can send the same credentials in each request.
287+
Setting this to `true` means that tokens will change on each request you make, and the new values will be returned
288+
in the headers. So your client needs to handle this.
297289
- **batch_request_buffer_throttle:** When change_headers_on_each_request is set to true, you might still want your
298290
credentials to be valid more than once as you might send parallel request. The duration you set here will
299291
determine how long the same credentials work after the first request is received.

0 commit comments

Comments
 (0)