refactored to fix Exec change bug