Fix: chart repo response code inconsistent

Response code should consistent whether namespace is existed or not

Signed-off-by: DQ <dengq@vmware.com>
This commit is contained in:
DQ 2020-05-26 15:16:27 +08:00
parent 3f4c8cc983
commit e1313da2f0

View File

@ -442,7 +442,7 @@ func (cra *ChartRepositoryAPI) requireNamespace(namespace string) bool {
// Not existing
if !existing {
cra.SendBadRequestError(fmt.Errorf("namespace %s is not existing", namespace))
cra.handleProjectNotFound(namespace)
return false
}