fix bug in toString.