Corrected the variable name in jnext to prevent reference errors.