Fixed creation of new namespaces

This commit is contained in:
konrad 2018-07-12 23:22:02 +02:00 committed by kolaente
parent e5493965ff
commit b24b245f4d
Signed by untrusted user: konrad
GPG Key ID: F40E70337AB24C9B
1 changed files with 1 additions and 0 deletions

View File

@ -6,6 +6,7 @@ func (n *Namespace) Create(doer *User, _ int64) (err error) {
if n.Name == "" {
return ErrNamespaceNameCannotBeEmpty{NamespaceID: 0, UserID: doer.ID}
}
n.ID = 0 // This would otherwise prevent the creation of new lists after one was created
// Check if the User exists
n.Owner, _, err = GetUserByID(doer.ID)