fix: don't try to load the namespace of a list if it is a shared list
This commit is contained in:
parent
c2b6119434
commit
d7e47a28d4
1 changed files with 1 additions and 5 deletions
|
@ -544,7 +544,7 @@ func (l *List) CheckIsArchived(s *xorm.Session) (err error) {
|
|||
func CreateOrUpdateList(s *xorm.Session, list *List, auth web.Auth) (err error) {
|
||||
|
||||
// Check if the namespace exists
|
||||
if list.NamespaceID != 0 && list.NamespaceID != FavoritesPseudoNamespace.ID {
|
||||
if list.NamespaceID > 0 {
|
||||
_, err = GetNamespaceByID(s, list.NamespaceID)
|
||||
if err != nil {
|
||||
return err
|
||||
|
@ -620,10 +620,6 @@ func CreateOrUpdateList(s *xorm.Session, list *List, auth web.Auth) (err error)
|
|||
}
|
||||
}
|
||||
|
||||
if err != nil {
|
||||
return
|
||||
}
|
||||
|
||||
l, err := GetListSimpleByID(s, list.ID)
|
||||
if err != nil {
|
||||
return err
|
||||
|
|
Loading…
Reference in a new issue