Finally fixed Java issue