gofmt -s on code.

This commit is contained in:
Chteufleur 2016-11-01 07:47:11 +01:00
parent e871a899f0
commit 1d5fce9b06
3 changed files with 3 additions and 3 deletions

View File

@ -226,7 +226,7 @@ func (g *GatewayInfo) SteamDisconnect() {
func (g *GatewayInfo) DisconnectAllSteamFriend() {
logger.Debug.Printf("[%s] Disconnect all Steam friend", g.XMPP_JID_Client)
for sid, _ := range g.FriendSteamId {
for sid := range g.FriendSteamId {
g.SendXmppPresence(Status_offline, Type_unavailable, "", sid+"@"+XmppJidComponent, "", "")
delete(g.FriendSteamId, sid)
}

View File

@ -230,7 +230,7 @@ func (g *GatewayInfo) addUserIntoRoster(jid, nick string) {
func (g *GatewayInfo) removeAllUserFromRoster() {
// Friends
for steamId, _ := range g.SteamClient.Social.Friends.GetCopy() {
for steamId := range g.SteamClient.Social.Friends.GetCopy() {
iq := xmpp.Iq{To: g.XMPP_JID_Client, Type: xmpp.IQTypeSet, Id: NextIqId()}
query := &xmpp.RosterQuery{}
query.Items = append(query.Items, *&xmpp.RosterItem{JID: steamId.ToString() + "@" + XmppJidComponent, Subscription: xmpp.RosterSubscriptionRemove})

View File

@ -282,7 +282,7 @@ func execCommandAdHoc(iq *xmpp.Iq) {
}
if message != "" {
// Succeeded
for userJID, _ := range MapGatewayInfo {
for userJID := range MapGatewayInfo {
SendMessage(userJID, "", message)
}
note.Value = "Message sended to all registered users"