JRH: E/Core: Allow an object for 'next:'. Make 'when:' optional if you want to use a default action.