add zh_TW locale, rename ssl to tls

This commit is contained in:
uubulb
2024-11-01 14:07:05 +08:00
parent 5114fc2854
commit ca997cc994
17 changed files with 455 additions and 62 deletions

View File

@@ -38,7 +38,7 @@ type Notification struct {
RequestType int `json:"request_type,omitempty"`
RequestHeader string `json:"request_header,omitempty" gorm:"type:longtext"`
RequestBody string `json:"request_body,omitempty" gorm:"type:longtext"`
VerifySSL *bool `json:"verify_ssl,omitempty"`
VerifyTLS *bool `json:"verify_tls,omitempty"`
}
func (ns *NotificationServerBundle) reqURL(message string) string {
@@ -111,7 +111,7 @@ func (n *Notification) setRequestHeader(req *http.Request) error {
func (ns *NotificationServerBundle) Send(message string) error {
var client *http.Client
n := ns.Notification
if n.VerifySSL != nil && *n.VerifySSL {
if n.VerifyTLS != nil && *n.VerifyTLS {
client = utils.HttpClient
} else {
client = utils.HttpClientSkipTlsVerify