fixed dismiss Bug