print function fix