Skip to content

Commit

Permalink
Fixup
Browse files Browse the repository at this point in the history
  • Loading branch information
takezoe committed Sep 24, 2017
1 parent 7554a45 commit f4b9f09
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 4 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@ import org.slf4j.LoggerFactory
import gitbucket.core.util.Implicits._

class AnnounceController extends AnnounceControllerBase
with AnnounceService with AccountService with SystemSettingsService with AdminAuthenticator
with AnnounceService with AccountService with AdminAuthenticator

trait AnnounceControllerBase extends ControllerBase {
self: AnnounceService with SystemSettingsService with AdminAuthenticator =>
Expand All @@ -34,7 +34,7 @@ trait AnnounceControllerBase extends ControllerBase {
})

post("/admin/announce", announceForm)(adminOnly { form =>
val systemSettings = loadSystemSettings()
val systemSettings = context.settings

if (systemSettings.useSMTP && systemSettings.smtp.nonEmpty) {
if (logger.isDebugEnabled) {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -13,15 +13,15 @@ object EmailAddress {
trait AnnounceService {
self: AccountService =>

def getAccountByGroupName(groupName: String, includeRemoved: Boolean = false)(implicit s: Session): List[Account] = {
def getAccountByGroupName(groupName: String)(implicit s: Session): List[Account] = {
val needs = GroupMembers
.filter(_.groupName === groupName.bind)
.sortBy(_.userName)
.map(_.userName)
.list

Accounts
.filter(t => (t.userName inSetBind needs) && (t.removed === false.bind, !includeRemoved))
.filter(t => (t.userName inSetBind needs) && (t.removed === false.bind))
.list
}

Expand Down

0 comments on commit f4b9f09

Please sign in to comment.