store vars after parsing arguments
refactor