fixed some things, cleaned up a bit