reorganise stuff
adding snippet to remove empty lines when splitting stings