Correctness check fixed