Skip to content

Commit ecbb1e3

Browse files
author
Adrián Quintás
committed
Add some logging
1 parent a9e240f commit ecbb1e3

File tree

3 files changed

+5
-2
lines changed

3 files changed

+5
-2
lines changed

README.md

+1-1
Original file line numberDiff line numberDiff line change
@@ -24,7 +24,7 @@ Add to dependencies
2424

2525
```elixir
2626
def deps do
27-
[{:server_utils, "~> 0.3.0"}]
27+
[{:server_utils, "~> 0.3.1"}]
2828
end
2929
```
3030

lib/plugs/session/jwt_session.ex

+3
Original file line numberDiff line numberDiff line change
@@ -7,6 +7,7 @@ defmodule ServerUtils.Plugs.Session.JwtSession do
77
import Plug.Conn
88

99
alias ServerUtils.Parsers.Jwt, as: JwtParser
10+
alias ServerUtils.SentryLogger
1011

1112
@authorization_header "authorization"
1213

@@ -30,9 +31,11 @@ defmodule ServerUtils.Plugs.Session.JwtSession do
3031
put_private(conn, :server_utils, private)
3132
else
3233
{:error, _} ->
34+
SentryLogger.info("Unable to parse claims from jwt: #{jwt}")
3335
send_unauthorized_response(conn)
3436
end
3537
else
38+
SentryLogger.debug("Header for authorization not found: #{@authorization_header}")
3639
send_unauthorized_response(conn)
3740
end
3841
end

mix.exs

+1-1
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@ defmodule ServerUtils.Mixfile do
22
@moduledoc false
33
use Mix.Project
44

5-
@version "0.3.0"
5+
@version "0.3.1"
66

77
def project do
88
[

0 commit comments

Comments
 (0)