1
0

Fix not able to make saved filters favorite

This commit is contained in:
kolaente
2021-04-03 16:49:20 +02:00
parent 9b7eef985e
commit 0b8173c1c3
9 changed files with 131 additions and 24 deletions

View File

@ -115,6 +115,17 @@ func (l *List) CanUpdate(s *xorm.Session, a web.Auth) (canUpdate bool, err error
if l.ID == FavoritesPseudoList.ID {
return false, nil
}
fid := getSavedFilterIDFromListID(l.ID)
if fid > 0 {
sf, err := getSavedFilterSimpleByID(s, fid)
if err != nil {
return false, err
}
return sf.CanUpdate(s, a)
}
canUpdate, err = l.CanWrite(s, a)
// If the list is archived and the user tries to un-archive it, let the request through
if IsErrListIsArchived(err) && !l.IsArchived {