Deleted unused variable ($TestForMessages)