middlewares

package
v0.0.0-...-e1bd9c8 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Aug 23, 2018 License: MIT Imports: 8 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var (
	ErrNotAdmin        = errors.New("Has not admin role.")
	ErrNotContentAdmin = errors.New("Has not content admin role.")
)

Functions

This section is empty.

Types

type JwtMiddleware

type JwtMiddleware struct {
	*jwt.GinJWTMiddleware
}

func GetAuthMiddleware

func GetAuthMiddleware() *JwtMiddleware

func (*JwtMiddleware) AdminMiddleware

func (mw *JwtMiddleware) AdminMiddleware(c *gin.Context)

func (*JwtMiddleware) ContentAdminMiddleware

func (mw *JwtMiddleware) ContentAdminMiddleware(c *gin.Context)

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL