Fixed boolean in wrong place