🎨 Clean code

This commit is contained in:
Daniel 2025-04-18 10:35:54 +08:00
parent f6654f5dde
commit 7a2fded724
No known key found for this signature in database
GPG key ID: 86211BA83DF03017
2 changed files with 2 additions and 2 deletions

View file

@ -297,7 +297,7 @@ func refreshAnnouncement() {
} }
} }
for _, announcement := range GetAnnouncements() { for _, announcement := range getAnnouncements() {
var exist bool var exist bool
for _, existingAnnouncement := range existingAnnouncements { for _, existingAnnouncement := range existingAnnouncements {
if announcement.Id == existingAnnouncement.Id { if announcement.Id == existingAnnouncement.Id {

View file

@ -233,7 +233,7 @@ type Announcement struct {
Region int `json:"region"` Region int `json:"region"`
} }
func GetAnnouncements() (ret []*Announcement) { func getAnnouncements() (ret []*Announcement) {
result, err := util.GetRhyResult(false) result, err := util.GetRhyResult(false)
if err != nil { if err != nil {
logging.LogErrorf("get announcement failed: %s", err) logging.LogErrorf("get announcement failed: %s", err)