Fixed bug in printing.