helpers

package
v0.0.0-...-2478899 Latest Latest
Warning

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

Go to latest
Published: May 2, 2024 License: MIT Imports: 8 Imported by: 0

Documentation

Overview

Package helpers defines the utility functions that are used across the application.

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func CheckSession

func CheckSession(c echo.Context) (*sessions.Session, bool)

CheckSession checks if the user is logged in or not returns the session and a boolean value

func CreateSession

func CreateSession(u *model.User, c echo.Context)

CreateSession creates a new session for the user

func DestroySession

func DestroySession(c echo.Context) error

DestroySession destroys the session for the user

func GetHashPassword

func GetHashPassword(password string) (string, error)

getHashPassword returns a hashed password using bcrypt and default cost

func IsMailValid

func IsMailValid(email string) bool

IsMailValid checks if the email is valid or not.

Types

This section is empty.

Jump to

Keyboard shortcuts

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