refactoring copyThemCommand to make it read more nicely #247