forked from forgejo/forgejo
Move accessmode into models/perm (#17828)
This commit is contained in:
parent
24a8d54bfb
commit
1fee11d69a
59 changed files with 359 additions and 295 deletions
|
@ -8,6 +8,7 @@ import (
|
|||
"net/url"
|
||||
|
||||
"code.gitea.io/gitea/models"
|
||||
"code.gitea.io/gitea/models/perm"
|
||||
api "code.gitea.io/gitea/modules/structs"
|
||||
)
|
||||
|
||||
|
@ -23,7 +24,7 @@ func ToNotificationThread(n *models.Notification) *api.NotificationThread {
|
|||
|
||||
//since user only get notifications when he has access to use minimal access mode
|
||||
if n.Repository != nil {
|
||||
result.Repository = ToRepo(n.Repository, models.AccessModeRead)
|
||||
result.Repository = ToRepo(n.Repository, perm.AccessModeRead)
|
||||
}
|
||||
|
||||
//handle Subject
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue