change static to singleton