diff options
author | Unknwon <u@gogs.io> | 2017-01-30 07:20:48 -0500 |
---|---|---|
committer | Unknwon <u@gogs.io> | 2017-01-30 07:20:48 -0500 |
commit | 4bc98f7aa2b94a18ddaef26f64ae01c2d38fb552 (patch) | |
tree | c3e3852d32a34bb1099b92585183493e9efa4d8b /routers/repo | |
parent | 207960b459d635667226d2d78f11ef3279ba9cc7 (diff) |
Move models/mail.go to modules/mail.go
To use interface to replace *models.User in avoiding cycle import.
Diffstat (limited to 'routers/repo')
-rw-r--r-- | routers/repo/setting.go | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/routers/repo/setting.go b/routers/repo/setting.go index 80b44ad2..52173827 100644 --- a/routers/repo/setting.go +++ b/routers/repo/setting.go @@ -15,6 +15,7 @@ import ( "github.com/gogits/gogs/modules/base" "github.com/gogits/gogs/modules/context" "github.com/gogits/gogs/modules/log" + "github.com/gogits/gogs/modules/mailer" "github.com/gogits/gogs/modules/setting" ) @@ -344,7 +345,7 @@ func CollaborationPost(ctx *context.Context) { } if setting.Service.EnableNotifyMail { - models.SendCollaboratorMail(u, ctx.User, ctx.Repo.Repository) + mailer.SendCollaboratorMail(models.NewMailerUser(u), models.NewMailerUser(ctx.User), models.NewMailerRepo(ctx.Repo.Repository)) } ctx.Flash.Success(ctx.Tr("repo.settings.add_collaborator_success")) |