m
This commit is contained in:
@@ -90,11 +90,14 @@ func main() {
|
|||||||
fund.Clear()
|
fund.Clear()
|
||||||
|
|
||||||
msg_ := fund.FundsMsg(user.Codes(true)...)
|
msg_ := fund.FundsMsg(user.Codes(true)...)
|
||||||
err = msg.Send(msg_)
|
if msg_ != "" {
|
||||||
if err != nil {
|
err = msg.Send(msg_)
|
||||||
logx.Errorf("fund msg send err: %v", err)
|
if err != nil {
|
||||||
|
logx.Errorf("fund msg send err: %v", err)
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
user.ForEachUser(func(u *user.User) bool {
|
user.ForEachUser(func(u *user.User) bool {
|
||||||
if u.IsStop() {
|
if u.IsStop() {
|
||||||
return true
|
return true
|
||||||
|
|||||||
@@ -78,9 +78,6 @@ func ForEachUser(f func(u *User) bool) {
|
|||||||
func Codes(isFund bool) []string {
|
func Codes(isFund bool) []string {
|
||||||
var codes = map[string]struct{}{}
|
var codes = map[string]struct{}{}
|
||||||
ForEachUser(func(u *User) bool {
|
ForEachUser(func(u *User) bool {
|
||||||
if u.IsStop() {
|
|
||||||
return true
|
|
||||||
}
|
|
||||||
cds := u.Codes(isFund)
|
cds := u.Codes(isFund)
|
||||||
for _, cd := range cds {
|
for _, cd := range cds {
|
||||||
if _, ok := codes[cd]; ok {
|
if _, ok := codes[cd]; ok {
|
||||||
|
|||||||
Reference in New Issue
Block a user