minor bugfixes and log events