Fix close automatic modal