Give single content line for files
Remove trailing newline character
BUGFIX : call lines method only for string values