fixed black flash bug