ueberauth / guardian

Elixir Authentication
MIT License
3.43k stars 382 forks source link

Elixir 1.8 prep #557

Closed sneako closed 5 years ago

sneako commented 5 years ago

Hi and thanks for the library! I was trying out 1.8-rc0 with one of my applications which depends on Guardian and got some new compiler warnings:

warning: deprecated time unit: :seconds. A time unit should be :second, :millisecond, :microsecond, :nanosecond, or a positive integer
  (guardian) lib/guardian/token/jwt.ex:406: Guardian.Token.Jwt.set_iat/1
  (guardian) lib/guardian/token/jwt.ex:276: Guardian.Token.Jwt.build_claims/5
  (guardian) lib/guardian.ex:756: Guardian.returning_tuple/1
  (guardian) lib/guardian.ex:580: Guardian.encode_and_sign/4

While fixing that warning I also noticed:

warning: invalid type annotation. When using the | operator to represent the union of types, make sure to wrap type annotations in parentheses: String.t() :: atom
  lib/guardian/permissions/bitwise.ex:109

This PR fixes these warnings.

codecov-io commented 5 years ago

Codecov Report

Merging #557 into master will not change coverage. The diff coverage is 100%.

Impacted file tree graph

@@           Coverage Diff           @@
##           master     #557   +/-   ##
=======================================
  Coverage   85.37%   85.37%           
=======================================
  Files          18       18           
  Lines         417      417           
=======================================
  Hits          356      356           
  Misses         61       61
Impacted Files Coverage Δ
lib/guardian/permissions/bitwise.ex 90.9% <ø> (ø) :arrow_up:
lib/guardian.ex 90% <100%> (ø) :arrow_up:
lib/guardian/plug.ex 83.78% <100%> (ø) :arrow_up:

Continue to review full report at Codecov.

Legend - Click here to learn more Δ = absolute <relative> (impact), ø = not affected, ? = missing data Powered by Codecov. Last update 0c3e8ee...2bc0e17. Read the comment docs.

doomspork commented 5 years ago

Thank you @sneako 👍