helpers

package
v0.0.0-...-7493986 Latest Latest
Warning

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

Go to latest
Published: Jan 1, 2021 License: MIT Imports: 10 Imported by: 0

Documentation

Index

Constants

View Source
const MAX_MEMORY = 1 * 1024 * 1024

Variables

This section is empty.

Functions

func CreateSession

func CreateSession(userID uint64, w http.ResponseWriter, r *http.Request)

func DestroySession

func DestroySession(w http.ResponseWriter)

func GenerateUID

func GenerateUID() uint64

func GetSession

func GetSession(request *http.Request) (userID uint64)

func UploadFiles

func UploadFiles(
	w http.ResponseWriter, r *http.Request,
	user uint64, category string) map[string]interface{}

func ValidateEmail

func ValidateEmail(email string) bool

func ValidatePassword

func ValidatePassword(password string) map[string]interface{}

Types

type GeneratedToken

type GeneratedToken struct {
	Token string `json:"token"`
}

type Token

type Token struct {
	Username string
	Password string
	jwt.StandardClaims
}

Jump to

Keyboard shortcuts

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