-various fixes and changes