org.jivesoftware.smackx.ping.PingManager.pingServerIfNecessary XMPPConnection was not authenticated

org.jivesoftware.smackx.ping.PingManager.pingServerIfNecessary XMPPConnection was not authenticated

How to resolve this message?

Is this a Smack question? Then you should move this to Smack forum (pencil icon near the title).