Skip to content

Commit

Permalink
Merge pull request #2035 from MSathieu/patch-1
Browse files Browse the repository at this point in the history
Update logging documentation
  • Loading branch information
bf4 authored Jan 31, 2017
2 parents ab824e2 + 1e47c16 commit 2d1c680
Show file tree
Hide file tree
Showing 2 changed files with 8 additions and 0 deletions.
1 change: 1 addition & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -16,6 +16,7 @@ Misc:

- [#2021](https://github.com/rails-api/active_model_serializers/pull/2021) Make test attributes explicit. Tests have Model#associations. (@bf4)
- [#1981](https://github.com/rails-api/active_model_serializers/pull/1981) Fix relationship link documentation. (@groyoh)
- [#2035](https://github.com/rails-api/active_model_serializers/pull/2035) Document how to disable the logger. (@MSathieu)
- [#2039](https://github.com/rails-api/active_model_serializers/pull/2039) Documentation fixes. (@biow0lf)

### [v0.10.4 (2017-01-06)](https://github.com/rails-api/active_model_serializers/compare/v0.10.3...v0.10.4)
Expand Down
7 changes: 7 additions & 0 deletions docs/general/logging.md
Original file line number Diff line number Diff line change
Expand Up @@ -12,3 +12,10 @@ You may customize the logger in an initializer, for example:
```ruby
ActiveModelSerializers.logger = Logger.new(STDOUT)
```

You can also disable the logger, just put this in `config/initializers/active_model_serializers.rb`:

```ruby
require 'active_model_serializers'
ActiveSupport::Notifications.unsubscribe(ActiveModelSerializers::Logging::RENDER_EVENT)
```

0 comments on commit 2d1c680

Please sign in to comment.