Skip to content

Commit

Permalink
Merge pull request #3 from bcmi-labs/401
Browse files Browse the repository at this point in the history
return an error if token is not active
  • Loading branch information
matteosuppo authored Aug 23, 2019
2 parents c14dd02 + 923450f commit a62ad03
Showing 1 changed file with 5 additions and 1 deletion.
6 changes: 5 additions & 1 deletion introspect/introspector.go
Original file line number Diff line number Diff line change
Expand Up @@ -87,8 +87,12 @@ func (m *Introspector) Introspect(token string) (*introspector.Introspection, er
if err != nil {
return nil, err
}
return &i, nil

if !i.Active {
return nil, errors.New("token not active")
}

return &i, nil
}

type req struct {
Expand Down

0 comments on commit a62ad03

Please sign in to comment.