Added Java version check