working on some of the bugs