We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent 60cebcc commit 38ae0b8Copy full SHA for 38ae0b8
1 file changed
collections/CreateCollection.go
@@ -14,6 +14,7 @@ import (
14
)
15
16
func CreateCollection(c *gin.Context) {
17
+
18
var body map[string]interface{}
19
if err := c.BindJSON(&body); err != nil {
20
c.JSON(http.StatusBadRequest, gin.H{"error": "Invalid request body"})
@@ -52,8 +53,8 @@ func CreateCollection(c *gin.Context) {
52
53
germanDate := now.Format("02.01.2006 15:04")
54
55
content := map[string]interface{}{
- "name": s,
56
- "date": germanDate,
+ "name": s,
57
+ "created": germanDate,
58
}
59
60
if err := encoder.Encode(content); err != nil {
0 commit comments