Fix close cursor