mirror of
https://codeberg.org/Codeberg/pages-server.git
synced 2025-04-25 06:16:58 +00:00
improve
This commit is contained in:
parent
1c5561231b
commit
aa21b81586
5 changed files with 26 additions and 24 deletions
|
@ -85,11 +85,11 @@ func migrateCerts(ctx *cli.Context) error {
|
|||
}
|
||||
|
||||
func listCerts(ctx *cli.Context) error {
|
||||
certDB, close, err := openCertDB(ctx)
|
||||
certDB, closeFn, err := openCertDB(ctx)
|
||||
if err != nil {
|
||||
return err
|
||||
}
|
||||
defer close()
|
||||
defer closeFn()
|
||||
|
||||
items, err := certDB.Items(0, 0)
|
||||
if err != nil {
|
||||
|
@ -115,11 +115,11 @@ func removeCert(ctx *cli.Context) error {
|
|||
|
||||
domains := ctx.Args().Slice()
|
||||
|
||||
certDB, close, err := openCertDB(ctx)
|
||||
certDB, closeFn, err := openCertDB(ctx)
|
||||
if err != nil {
|
||||
return err
|
||||
}
|
||||
defer close()
|
||||
defer closeFn()
|
||||
|
||||
for _, domain := range domains {
|
||||
fmt.Printf("Removing domain %s from the database...\n", domain)
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue