Code cleanup + getting rid of saveEntry flag, using input string instead.