output and bugfix