👔 Return base site if language specific site was not found
/ docker (push) Successful in 1m1s Details

This commit is contained in:
Maxim Lebedev 2023-11-08 07:18:49 +06:00
parent 67f575c5d0
commit e419998759
Signed by: toby3d
GPG Key ID: 1F14E25B7C119FC5
1 changed files with 1 additions and 1 deletions

View File

@ -28,7 +28,7 @@ func (ucase *siteUseCase) Do(ctx context.Context, lang language.Tag) (*domain.Si
sub, err := ucase.sites.Get(ctx, lang)
if err != nil {
return nil, fmt.Errorf("cannot find site data for '%s' language code: %w", lang, err)
return base, nil
}
out := &domain.Site{Language: sub.Language}