소스 검색

rename json fields

v2ray 9 년 전
부모
커밋
be81d246f2
1개의 변경된 파일2개의 추가작업 그리고 2개의 파일을 삭제
  1. 2 2
      transport/internet/connection_json.go

+ 2 - 2
transport/internet/connection_json.go

@@ -13,11 +13,11 @@ import (
 
 func (this *TLSSettings) UnmarshalJSON(data []byte) error {
 	type JSONCertConfig struct {
-		CertFile string `json:"certFile"`
+		CertFile string `json:"certificateFile"`
 		KeyFile  string `json:"keyFile"`
 	}
 	type JSONConfig struct {
-		Certs []*JSONCertConfig `json:"certs"`
+		Certs []*JSONCertConfig `json:"certificates"`
 	}
 	jsonConfig := new(JSONConfig)
 	if err := json.Unmarshal(data, jsonConfig); err != nil {