Small bugfixes and cleanup.