Fix extra write header.

This commit is contained in:
Mariano Cano 2019-11-21 19:06:19 -08:00
parent 87ce2c9b4b
commit 864dd3cf1f
2 changed files with 4 additions and 6 deletions

View file

@ -71,8 +71,7 @@ func (h *caHandler) SSHRekey(w http.ResponseWriter, r *http.Request) {
return
}
w.WriteHeader(http.StatusCreated)
JSON(w, &SSHSignResponse{
JSONStatus(w, &SSHSignResponse{
Certificate: SSHCertificate{newCert},
})
}, http.StatusCreated)
}

View file

@ -61,8 +61,7 @@ func (h *caHandler) SSHRenew(w http.ResponseWriter, r *http.Request) {
return
}
w.WriteHeader(http.StatusCreated)
JSON(w, &SSHSignResponse{
JSONStatus(w, &SSHSignResponse{
Certificate: SSHCertificate{newCert},
})
}, http.StatusCreated)
}