Versions in this module Expand all Collapse all v0 v0.0.4 Apr 16, 2024 Changes in this version + func IsDuplicatedKeyError(err error) bool + func IsNotFoundError(err error) bool + type Storage struct + func New(cfg *config.Config) (*Storage, error) + func (s *Storage) Close() + func (s *Storage) DelAdmin(ctx context.Context, email string, appName string) error + func (s *Storage) DelApp(ctx context.Context, appName string) error + func (s *Storage) GetApp(ctx context.Context, appName string) (models.App, error) + func (s *Storage) GetAppID(ctx context.Context, appName string) (models.App, error) + func (s *Storage) GetUser(ctx context.Context, email string) (models.User, error) + func (s *Storage) IsAdmin(ctx context.Context, userID uint64, appName string) error + func (s *Storage) IsCreator(ctx context.Context, userID uint64, appName string) error + func (s *Storage) SaveUser(ctx context.Context, email string, passHash []byte) (uint64, error) + func (s *Storage) SetAdmin(ctx context.Context, email string, appName string) error + func (s *Storage) SetApp(ctx context.Context, appName string, appSecret string) (int, error) + func (s *Storage) SetCreator(ctx context.Context, userID uint64, appID int) error + func (s *Storage) UpdApp(ctx context.Context, appName, newAppName, newAppSecret string) error v0.0.3 Apr 16, 2024