Fixed server connection/registration callback race condition