--- a/trunk/tubetutor/tubetutor.py
+++ b/trunk/tubetutor/tubetutor.py
@@ -112,7 +112,7 @@
 
 	def get_title(self):
 		title=self.textfields["title"].get("1.0", tkinter.END)
-		return title
+		return title.replace("\n", "")
 
 
 	def refresh_files(self):
@@ -125,10 +125,13 @@
 
 	# Output the main window
 	def refresh_display(self):
-		# remove all widgets
-		for w in self.buttons:
-			self.buttons[w].pack_forget()
-		self.buttons = {}
+	    # remove all widgets
+		try:
+			for w in self.buttons:
+				self.buttons[w].pack_forget()
+			self.buttons = {}
+		except:
+			pass
 
 		for w in self.frames:
 			w.pack_forget()