reorder auth interface (#1204)

This commit is contained in:
Asim Aslam 2020-02-16 19:36:45 +00:00 committed by GitHub
parent b3fc8be24e
commit 9696efde02
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -7,8 +7,6 @@ import (
// Auth providers authentication and authorization // Auth providers authentication and authorization
type Auth interface { type Auth interface {
// String to identify the package
String() string
// Init the auth package // Init the auth package
Init(opts ...Option) error Init(opts ...Option) error
// Options returns the options set // Options returns the options set
@ -19,6 +17,8 @@ type Auth interface {
Revoke(token string) error Revoke(token string) error
// Validate an account token // Validate an account token
Validate(token string) (*Account, error) Validate(token string) (*Account, error)
// String returns the implementation
String() string
} }
// Resource is an entity such as a user or // Resource is an entity such as a user or