diff options
Diffstat (limited to 'internal/config/validate.go')
-rw-r--r-- | internal/config/validate.go | 8 |
1 files changed, 8 insertions, 0 deletions
diff --git a/internal/config/validate.go b/internal/config/validate.go index 064eae07a..b9fdb013b 100644 --- a/internal/config/validate.go +++ b/internal/config/validate.go @@ -67,6 +67,14 @@ func Validate() error { errs = append(errs, fmt.Errorf("%s must be set", WebAssetBaseDirFlag())) } + if m := GetMediaEmojiLocalMaxSize(); m < 0 { + errs = append(errs, fmt.Errorf("%s must not be less than 0", MediaEmojiLocalMaxSizeFlag())) + } + + if m := GetMediaEmojiRemoteMaxSize(); m < 0 { + errs = append(errs, fmt.Errorf("%s must not be less than 0", MediaEmojiRemoteMaxSizeFlag())) + } + if len(errs) > 0 { errStrings := []string{} for _, err := range errs { |