only print data if its not empty.