fixed quit issue