Quick patch to solve issue of multiplying newlines. Consider changing to a better check than just if len(line) > 2