Correct the position of closing bracket