@@ -1,16 +1,17 @@
|
||||
package handler
|
||||
|
||||
import (
|
||||
"encoding/json"
|
||||
"honoka-chan/internal/model"
|
||||
"honoka-chan/internal/utils"
|
||||
"net/http"
|
||||
"honoka-chan/internal/session"
|
||||
"time"
|
||||
|
||||
"github.com/gin-gonic/gin"
|
||||
)
|
||||
|
||||
func PersonalNotice(ctx *gin.Context) {
|
||||
ss := session.New(ctx)
|
||||
defer ss.Finalize()
|
||||
|
||||
noticeResp := model.PersonalNoticeResp{
|
||||
ResponseData: model.PersonalNoticeRes{
|
||||
HasNotice: false,
|
||||
@@ -23,9 +24,6 @@ func PersonalNotice(ctx *gin.Context) {
|
||||
ReleaseInfo: []any{},
|
||||
StatusCode: 200,
|
||||
}
|
||||
resp, err := json.Marshal(noticeResp)
|
||||
utils.CheckErr(err)
|
||||
|
||||
ctx.Header("X-Message-Sign", utils.GenXMS(resp))
|
||||
ctx.String(http.StatusOK, string(resp))
|
||||
ss.Respond(noticeResp)
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user