fixing the flaag and something else that I don't remember