mirror of
https://codeberg.org/forgejo/forgejo.git
synced 2025-06-01 04:12:10 +00:00
Move user functions into user.go (#17659)
* Move user functions into user.go * Fix test
This commit is contained in:
parent
6874fe90e5
commit
3c3855a05c
14 changed files with 101 additions and 72 deletions
|
@ -7,7 +7,7 @@ package repo
|
|||
import (
|
||||
"fmt"
|
||||
|
||||
"code.gitea.io/gitea/models"
|
||||
admin_model "code.gitea.io/gitea/models/admin"
|
||||
"code.gitea.io/gitea/modules/context"
|
||||
"code.gitea.io/gitea/modules/git"
|
||||
)
|
||||
|
@ -23,7 +23,7 @@ func SetEditorconfigIfExists(ctx *context.Context) {
|
|||
|
||||
if err != nil && !git.IsErrNotExist(err) {
|
||||
description := fmt.Sprintf("Error while getting .editorconfig file: %v", err)
|
||||
if err := models.CreateRepositoryNotice(description); err != nil {
|
||||
if err := admin_model.CreateRepositoryNotice(description); err != nil {
|
||||
ctx.ServerError("ErrCreatingReporitoryNotice", err)
|
||||
}
|
||||
return
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue