bugfixes/improvements