fix bug in output generation