Fix getting one namespace

Signed-off-by: kolaente <k@knt.li>
This commit is contained in:
kolaente 2020-03-21 13:55:42 +01:00
parent 51c74de1de
commit 26ffd2fd22
No known key found for this signature in database
GPG key ID: F40E70337AB24C9B

View file

@ -133,8 +133,7 @@ func (n *Namespace) CheckIsArchived() error {
// @Failure 500 {object} models.Message "Internal error"
// @Router /namespaces/{id} [get]
func (n *Namespace) ReadOne() (err error) {
// Get the namespace Owner
n.Owner, err = user.GetUserByID(n.OwnerID)
*n, err = GetNamespaceByID(n.ID)
return
}