Bugfix and extra documentation