small changes and cleanup