Fix deprecated setFlash() call