fix flash problem