mirror of
https://github.com/Floriansylvain/RenewCMS.git
synced 2026-08-19 19:53:21 +02:00
Complete file tree and packages managment rework
This commit is contained in:
@@ -0,0 +1,19 @@
|
||||
package api
|
||||
|
||||
import (
|
||||
"net/http"
|
||||
|
||||
"github.com/gin-gonic/gin"
|
||||
)
|
||||
|
||||
func SendBadRequest(c *gin.Context, message string) {
|
||||
c.JSON(http.StatusBadRequest, gin.H{"message": message})
|
||||
}
|
||||
|
||||
func SendOk(c *gin.Context, message string) {
|
||||
c.JSON(http.StatusOK, gin.H{"message": message})
|
||||
}
|
||||
|
||||
func SendForbidden(c *gin.Context, message string) {
|
||||
c.JSON(http.StatusForbidden, gin.H{"message": message})
|
||||
}
|
||||
Reference in New Issue
Block a user