middlewares

package
v0.0.0-...-0529349 Latest Latest
Warning

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

Go to latest
Published: Sep 9, 2019 License: MIT Imports: 6 Imported by: 0

Documentation

Overview

Package middlewares provides common middleware handlers.

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func Logging

func Logging() func(http.Handler) http.Handler

func MustLogin

func MustLogin(next http.Handler) http.Handler

MustLogin is a middleware that checks existence of current user.

func SetDB

func SetDB(db *sqlx.DB) func(http.Handler) http.Handler

func SetMongo

func SetMongo(db *mongo.Database) func(http.Handler) http.Handler

func SetSessionStore

func SetSessionStore(sessionStore sessions.Store) func(http.Handler) http.Handler

Types

This section is empty.

Jump to

Keyboard shortcuts

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