fixed trailing newlines