diff --git a/services/xmppsService.go b/services/xmppsService.go index 67a6b6c..80751f1 100644 --- a/services/xmppsService.go +++ b/services/xmppsService.go @@ -118,7 +118,7 @@ func Init() { go func() { - statusMesageDelay := int64(rand.Intn(appConfig.AppConfig.GeneralOptions.StatusMessageDelay)) + statusMesageDelay := int64(rand.Intn(appConfig.AppConfig.GeneralOptions.CommandReplyDelay)) log.Printf("DELAYING FOR: %v", statusMesageDelay*1000000000) // Delay For two seccond to allow all clients to connect time.Sleep(time.Duration(statusMesageDelay * 1000000000)) @@ -152,7 +152,7 @@ func Init() { // SendOnlinePresenceStanza - send online presence stnza with data, to server func SendOnlinePresenceStanza(client *xmpp.Client, jid string) error { - statusMesageDelay := int64(rand.Intn(appConfig.AppConfig.GeneralOptions.StatusMessageDelay)) + statusMesageDelay := int64(rand.Intn(appConfig.AppConfig.GeneralOptions.CommandReplyDelay)) log.Printf("DELAYING FOR: %v", statusMesageDelay*1000000000) // Delay For two seccond to allow all clients to connect time.Sleep(time.Duration(statusMesageDelay * 1000000000))