1
0
mirror of https://github.com/pocketbase/pocketbase.git synced 2025-03-29 17:10:44 +02:00

renamed local field var

This commit is contained in:
Gani Georgiev 2024-11-11 00:03:25 +02:00
parent 339399b0a4
commit 7119ff4716

View File

@ -739,14 +739,14 @@ func (f *FileField) toSliceValue(raw any) []any {
}
func (f *FileField) uniqueFiles(files []any) []any {
existing := make(map[string]struct{}, len(files))
found := make(map[string]struct{}, len(files))
result := make([]any, 0, len(files))
for _, fv := range files {
name := f.getFileName(fv)
if _, ok := existing[name]; !ok {
if _, ok := found[name]; !ok {
result = append(result, fv)
existing[name] = struct{}{}
found[name] = struct{}{}
}
}