update to docs and some bugfixes