fix double init problem in client