rename postgr fucntions

This commit is contained in:
gitGnome
2026-04-15 14:18:22 +02:00
parent 3c31e82061
commit 6d0eaa92e9
7 changed files with 49 additions and 40 deletions
+3 -3
View File
@@ -39,7 +39,7 @@ func GetKey(hash string, contentType string) string {
return hash + extensionFromContentType(contentType)
}
func MinInit() {
func Init() {
ctx := context.Background()
var err error
@@ -65,14 +65,14 @@ func MinInit() {
}
func Upload(ctx context.Context, key string, body io.Reader, size int64, contentType string, uploader uuid.UUID) error {
func Upload(ctx context.Context, key string, body io.Reader, size int64, contentType string, id uuid.UUID) error {
_, err := minClient.PutObject(ctx, globals.FileStorageBucketName, key, body, size,
minio.PutObjectOptions{
ContentType: contentType,
PartSize: globals.FileProcessingPartSize,
NumThreads: globals.FileProcessingThreads,
UserMetadata: map[string]string{
"uploader": uploader.String(),
"id": id.String(),
},
})
return err