fix some bugs add some functionality