did some bugfixes