fix filenames

This commit is contained in:
2026-07-24 18:24:49 +07:00
parent c6a561f570
commit 1bab74d8ca
3 changed files with 68 additions and 0 deletions
@@ -3,6 +3,7 @@ package file_service
import (
"context"
"evening_detective_server/internal/modules/file_storage"
"evening_detective_server/internal/modules/string_tools"
)
type FileService struct {
@@ -21,6 +22,7 @@ func (s *FileService) UploadFile(
ctx context.Context,
file *file_storage.File,
) (string, error) {
file.Name = string_tools.Transliterate(file.Name)
if err := s.fileStorage.Put(ctx, file); err != nil {
return "", err
}