bugfixes in export