Cleaned up usage for jni env