package Models

import (
	"time"

	"github.com/gofrs/uuid"
)

func (s Session) IsExpired() bool {
	return s.Expiry.Before(time.Now())
}

type Session struct {
	Base
	UserID uuid.UUID `gorm:"type:uuid;column:user_id;not null;"`
	User   User
	Expiry time.Time
}
