♻️ Code style: Adjust comment formatting (#17299)

This commit is contained in:
Jeffrey Chen 2026-03-22 11:05:22 +08:00 committed by GitHub
parent 9497f5dc1b
commit 60fa7fe545
No known key found for this signature in database
GPG key ID: B5690EEEBB952194
2 changed files with 5 additions and 5 deletions

View file

@ -97,7 +97,7 @@ var (
ErrorCardDavAddressFileExtensionNameInvalid = errors.New("CardDAV: address file extension name is invalid")
)
// ImportVCardFile imports a address book from a vCard file (*.vcf)
// ImportAddressBook imports an address book from a vCard file (*.vcf)
func ImportAddressBook(addressBookPath, cardContent string) (addresses []*AddressObject, err error) {
// TODO: Check whether the path is valid (PathDepth: Address)
// TODO: Check whether the address book exists
@ -106,7 +106,7 @@ func ImportAddressBook(addressBookPath, cardContent string) (addresses []*Addres
return
}
// ExportAddressBook exports a address book to a vCard file (*.vcf)
// ExportAddressBook exports an address book to a vCard file (*.vcf)
func ExportAddressBook(addressBookPath string) (cardContent string, err error) {
// TODO: Check whether the path is valid (PathDepth: AddressBook)
// TODO: Check whether the address book exists
@ -114,7 +114,7 @@ func ExportAddressBook(addressBookPath string) (cardContent string, err error) {
return
}
// AddressBooksMetaDataFilePath returns the absolute path of the address books meta data file
// AddressBooksMetaDataFilePath returns the absolute path of the address books metadata file
func AddressBooksMetaDataFilePath() string {
return DavPath2DirectoryPath(CardDavAddressBooksMetaDataFilePath)
}

View file

@ -42,7 +42,7 @@ const (
TLSKeyFilename = "key.pem"
)
// Returns paths to existing TLS certificates or generates new ones signed by a local CA.
// GetOrCreateTLSCert returns paths to existing TLS certificates or generates new ones signed by a local CA.
// Certificates are stored in the conf directory of the workspace.
func GetOrCreateTLSCert() (certPath, keyPath string, err error) {
certPath = filepath.Join(ConfDir, TLSCertFilename)
@ -278,7 +278,7 @@ func writeCertAndKey(certPath, keyPath string, certDER []byte, privateKey *ecdsa
return nil
}
// Imports a CA certificate and private key from PEM-encoded strings.
// ImportCABundle imports a CA certificate and private key from PEM-encoded strings.
func ImportCABundle(caCertPEM, caKeyPEM string) error {
certBlock, _ := pem.Decode([]byte(caCertPEM))
if certBlock == nil {