1
0

Edit a post is actually should be of method PATCH.

This commit is contained in:
Alexander Andreev 2023-05-22 04:14:39 +04:00
parent 91a76fb9d7
commit fc4512a625
Signed by: Arav
GPG Key ID: D22A817D95815393

View File

@ -103,7 +103,7 @@ func main() {
mindflowApi := http.NewMindflowApiHandlers(mindflowDB) mindflowApi := http.NewMindflowApiHandlers(mindflowDB)
srv.POST("/api/mindflow", mindflowApi.New) srv.POST("/api/mindflow", mindflowApi.New)
srv.POST("/api/mindflow/:id", mindflowApi.Edit) srv.PATCH("/api/mindflow/:id", mindflowApi.Edit)
srv.DELETE("/api/mindflow/:id", mindflowApi.Delete) srv.DELETE("/api/mindflow/:id", mindflowApi.Delete)
if err := srv.Start(network, *listenAddress); err != nil { if err := srv.Start(network, *listenAddress); err != nil {