Merge upstream monitoring features preserving domain extensions and require fixed Go toolchain

This commit is contained in:
Codex committed 2026-10-22 23:50:03 +08:00
commit 71dd21269b
92 files changed
+8557 -874

No files matched your search

+6
View File
@@ -1,6 +1,7 @@
package controller
import (
"net/http"
"slices"
"strconv"
@@ -12,6 +13,8 @@ import (
"github.com/nezhahq/nezha/service/singleton"
)
const notificationBatchDeleteMaxBodyBytes = 1 << 20
// List notification
// @Summary List notification
// @Security BearerAuth
@@ -176,6 +179,9 @@ func updateNotification(c *gin.Context) (any, error) {
// @Router /batch-delete/notification [post]
func batchDeleteNotification(c *gin.Context) (any, error) {
var n []uint64
if c.Request != nil && c.Request.Body != nil {
c.Request.Body = http.MaxBytesReader(c.Writer, c.Request.Body, notificationBatchDeleteMaxBodyBytes)
}
if err := c.ShouldBindJSON(&n); err != nil {
return nil, err
}