mirror of
https://github.com/pocketbase/pocketbase.git
synced 2026-10-12 01:07:27 +02:00
ucfirst the DynamicModel field name so that we can use later the same FieldMapper resolver rules
This commit is contained in:
1 parent
dad289b90d
commit
1cbf16b3bf
1 file changed
+1
-1
+1
-1
@@ -455,7 +455,7 @@ func newDynamicModel(shape map[string]any) any {
|
||||
shapeValues = append(shapeValues, reflect.ValueOf(v))
|
||||
|
||||
structFields = append(structFields, reflect.StructField{
|
||||
Name: strings.ToUpper(k), // ensures that the field is exportable
|
||||
Name: strings.Title(k), // ensures that the field is exportable
|
||||
Type: vt,
|
||||
Tag: reflect.StructTag(`db:"` + k + `" json:"` + k + `"`),
|
||||
})
|
||||
|
||||
Reference in new issue
Block a user