Fix after conversion to Java.