fixed newline bugs