19 lines
782 B
Go
19 lines
782 B
Go
// Package domain contains pure domain models with no external dependencies.
|
|
// These types represent the core business concepts of the service.
|
|
package domain
|
|
|
|
import "errors"
|
|
|
|
// Domain errors - these are business-level errors that should be translated
|
|
// to appropriate HTTP status codes by the handler layer.
|
|
var (
|
|
// ErrInvalidTheme indicates an invalid theme value was provided.
|
|
ErrInvalidTheme = errors.New("theme must be one of: light, dark, system")
|
|
|
|
// ErrInvalidLanguage indicates an invalid language value was provided.
|
|
ErrInvalidLanguage = errors.New("language must be one of: en, fr, es, de, ja")
|
|
|
|
// ErrInvalidDigest indicates an invalid digest frequency was provided.
|
|
ErrInvalidDigest = errors.New("notifications.digest must be one of: none, daily, weekly")
|
|
)
|