dispatch keywords condition refactor