changed bool from static to class member