Fix flash as suggested by @lord