README.md in identity-gateway-1.0.2 vs README.md in identity-gateway-1.1.0
- old
+ new
@@ -1,10 +1,9 @@
# Identity::Gateway
-[![Gem Version][GV img]][Gem Version]
-[Gem Version]: https://rubygems.org/gems/identity-gateway
-[GV img]: https://img.shields.io/gem/v/identity-gateway.svg
+[![Gem Version](https://img.shields.io/gem/v/identity-gateway.svg)](https://rubygems.org/gems/identity-gateway)
+[![CircleCI](https://circleci.com/gh/wamland-team/identity-gateway.svg?style=shield&circle-token=b03fdcc75674d173f58a296cb1a3b2162b6828dc)](https://circleci.com/gh/wamland-team/identity-gateway)
Identity's gateway provider for Ruby and Rails applications. Act as a man in the middle between backend services and Identity.
## Installation
@@ -86,13 +85,13 @@
render json: { message: 'You need to sign in before continuing.' }, status: :unauthorized
end
end
```
-Alternatively, you can globally handle Identity::Gateway::Unauthorized's by having rails handle them as a 403 error and serving a 403 error page. Add the following to application.rb:
+Alternatively, you can globally handle Identity::Gateway::Unauthorized's by having rails handle them as a 401 error and serving a 401 error page. Add the following to application.rb:
```ruby
-config.action_dispatch.rescue_responses['Identity::Gateway::Unauthorized'] = :forbidden
+config.action_dispatch.rescue_responses['Identity::Gateway::Unauthorized'] = :unauthorized
```
## Configuration
You can configure Identity::Gateway by creating an initializer `config/initializers/identity_gateway.rb` and passing it a `configure` block: